How to Reset WordPress Admin Password
WordPress provides a few options to reset or change your WordPress Admin Password. If you want to change your password or forget the old password, You want to Reset that, There are many ways to update that.
Why Should You Change Your WordPress Password?
It is possible things to someone found your website password, When you forget the password & For maintaining the security, Every 60 Days we have to change or reset the password of the Website.
So, it is necessary to change or reset the password.
What is the difference between changing a password and resetting a password?
We have to change our password when we know our present password.
We have to reset our password when we don’t know our current password but have created a password profile.
There are many options like –
- Via the Dashboard
- Using the Default Login Screen
- Using phpMyAdmin – cPanel
- via FTP
- Using Reset Script
Dashboard through Reset WordPress Password
- Go to Dashboard -> Users
- Hover to the Admin User And then Click on the Edit link.
- Scroll Down & In the Account Manager Section, You can display the Label NEW Password and right side Set NEW PASSWORD button.
- Click on that Button, By default you display the Random Password.
- Now, You should remove that Random Password & Add your own Password with capital letters, numbers, and a symbol to help make the password strong and hard to crack.
- If the password is set, then click on the Update Profile button.
- After Login with that new password.
Default Login Screen through Reset WordPress Password
- Logout the current site And wp-admin through open Default Login Screen.
- There we have seen the Lost your Password? Link.
- Click on that link, And Redirect to the Reset Password screen.
- Here, you can enter your username or the email address you used for your WordPress account.
- Then Click on Get New Password Button and you will receive a link on your registered email address to create a new password via email.
- Check Registered Email Inbox, You will get a Reset Password Link.
- After successfully, Reset Password Login With the password.
Without Any type of Email Configuration, It will not work for sending or receiving mail. Email Configuration is necessary to Reset the Password. When successfully done email configuration, Then we have to receive Reset Password Link when we click on Lost your Password -> New Password – User Name / Email Address -> Get NEW Password Button.
phpMyAdmin through Reset WordPress Password
- Before making any changes first, You have to take a Backup.
- Login into the cPanel, Under the database section, click on the PHPMyAdmin.
- Click on the database name, Which you want to reset the password.
- Then after you can see the all WordPress table details, that are used to store WordPress site information.
- You can select the wp_users table, Then choose the user whose password you want to modify and click on the Edit link.
- In the user_pass field, select MD5 from the dropdown menu and replace the existing encrypted password with the new password under Value. You can type plain text. After saving, it will be encrypted automatically.
- After Adding that, Click on the Go button. New password saved successfully and encrypted automatically.
FTP through Reset WordPress Password
- If you have Don’t access to the WordPress database, You can Also Reset the Password via FTP.
- Login into the FTP, And go to the wp-content -> themes -> themename -> functions.php file.
- In php code, wp_set_password(‘password2021′,’admin’);
- After save the file, Password Automatically Reset.
- In this example, we are updating the password to password2021, and we are updating it for the user admin, if your admin user has a different username then you can add it with a different name.
- Without FTP we also Update that – Dashboard -> Appearance -> Theme Editor -> choose a theme and go to function.php then we can add that function.
Reset Script through Reset the WordPress Password
- Click on to here save script – Save the script as a file called emergency.php to the root of your WordPress installation (the same directory that contains wp-config.php).
- In your browser, open http://example.com/emergency.php
- Enter the administrator admin username and the new password, then click Update Options. A message is displayed noting the changed password. An email is sent to the blog administrator with the changed password information.
- Remove the emergency.php from your server when you are done. Do not leave it on your server as someone else could use it to change your password.
- You must know the admin username in order to use the script.
- The script then sends an email to the admin’s registered email address, to reset the admin password.
- Even if you do not receive an email, your password has been reset automatically.
- The script file is stored as the root directory of the wp-config.php file.
- After resetting the password, Remove the script. For security reasons, it is necessary to remove it.