Family Encyclopedia >> Electronics

How to remove WordPress reset/change password option

Are you looking to remove the reset password option in WordPress? By default, WordPress allows users to reset/change password by providing their email address. Sometimes you may want to disable the password reset option in WordPress. In this article, we will show you how to remove WordPress password reset/change option.

How to remove WordPress reset/change password option

Why remove WordPress password reset/change option?

If you allow user registration on your WordPress site, then the password reset option allows the user to recover lost passwords. Normally, you wouldn't want to change that.

However, in some usage scenarios, you may want to remove this option for specific users or user roles on your WordPress site.

For example, if you've created a temporary account for someone, or if you've created a demo site where users can log in with a demo username and password.

The easiest solution will be to simply remove the password reset link. But some smart users may already know the URL to access the password reset form.

With that being said, let’s see how you can easily remove WordPress password reset/change option.

Method 1:Disable reset/change password option using plugin

The plugin method is better and easier. It allows you to disable the password reset option for specific user roles or even individual users.

This way you can still control and provide the password reset function for some trusted users or user roles.

The first thing you need to do is install and activate the Plainview Protect Passwords plugin. For more details, check out our step-by-step guide on how to install a WordPress plugin.

After activation, you need to visit Settings »Protect passwords page to configure plugin settings.

How to remove WordPress reset/change password option

Simply select user roles or individual users to disable your password change or reset option.

There is also an option to exempt individual users. This option is useful if you want to disable the password reset option for all users except yourself.

Don't forget to click the Save Changes button to store your settings.

You can see the plugin in action by visiting the WordPress login page and clicking "Lost your password?" link. It will take you to the password reset page, where you can try entering the username or email address of a user who does not have the password reset option.

You will see an error that password reset is not allowed for this user.

How to remove WordPress reset/change password option

Method 2:Manually disable WordPress password reset option

This method requires you to add code to your WordPress site. It is not recommended for beginner level users.

The first thing to do is open a blank text file with a text editor like Notepad. Paste the following code into this file.

 CARNÉ DE IDENTIDAD); if (! empty ($ user-> roles) && is_array ($ user-> roles) && $ user-> roles [0] == 'administrador') devuelve verdadero; falso retorno; function remove ($ text) return str_replace (array ('¿Perdió su contraseña?', 'Perdió su contraseña'), ", trim ($ text, '?')); $ pass_reset_removed = new Password_Reset_Removed (); ?> 

Save this file as disable-password-reset.php on your desk.

Now you need to upload this file to your WordPress site. You will need an FTP client to do that. See our guide on how to use FTP to upload WordPress files.

Connect to your website using the FTP client and then go to the plugins folder. The plugin folder is located inside the /wp-content/ directory.

How to remove WordPress reset/change password option

Upload disable-password-reset.php file from your computer to the plugins folder on your WordPress site.

Now you need to login to the WordPress admin area and visit the plugins page. You will see a new plugin titled 'Disable Password Reset' in your list of installed plugins. Click on the activation link below the plugin.

How to remove WordPress reset/change password option

That's it, activating the plugin will disable the password reset option for all users, including administrators. Administrators will be able to change passwords from the admin area, but will not be able to reset the password from the login screen.

We hope this article helped you learn how to remove WordPress password reset/change option. You may also want to see our list of 13 plugins and tips to improve your WordPress admin area.

If you enjoyed this article, please subscribe to our WordPress YouTube Channel video tutorials. You can also find us on Twitter and Facebook.