Here’s a detailed guide on How to Reset a WordPress Password from phpMyAdmin:
How to Reset WordPress Password from phpMyAdmin
If you’ve forgotten your WordPress admin password and are unable to reset it via the WordPress login page, you can manually reset it through phpMyAdmin by directly updating the password in the WordPress database. Follow these steps to reset your WordPress password.
Step 1: Log in to cPanel
- Open your web browser and navigate to your cPanel login page (e.g.,
https://yourdomain.com/cpanel
). - Enter your cPanel username and password, then click Log in.
Step 2: Access phpMyAdmin
- In the Databases section of the cPanel dashboard, locate and click on phpMyAdmin.
- This will open the phpMyAdmin interface in a new tab.
Step 3: Select Your WordPress Database
- In phpMyAdmin, you will see a list of databases on the left sidebar.
- Click on the database associated with your WordPress site. If you are unsure which one it is, you can check the database name in the wp-config.php file located in the root directory of your WordPress installation via File Manager or FTP.
Step 4: Open the wp_users Table
- Once you’ve selected the correct database, you will see a list of tables.
- Locate the table named wp_users (the prefix may be different if you’ve changed it during installation, e.g.,
xyz_users
). - Click on the wp_users table to view its contents.
Step 5: Locate Your Username
- In the wp_users table, you will see a list of users registered on your WordPress site.
- Find the row corresponding to the user whose password you want to reset (usually the admin account).
- Click the Edit link next to that user’s row to modify the user’s details.
Step 6: Change the Password
- In the user_pass field, you will see the current password, which is encrypted.
- Delete the current password and replace it with your new password.
- In the Function dropdown next to the user_pass field, select MD5. This will encrypt your new password using the MD5 hash function.
- Note: WordPress versions 4.3 and later no longer use MD5, but this step is necessary in phpMyAdmin as the system will automatically rehash the password upon login.
Step 7: Save the Changes
- Scroll down and click the Go button at the bottom of the page to save your changes.
- Your password has now been updated in the database.
Step 8: Log in to WordPress
- Go back to the WordPress login page (
https://yourdomain.com/wp-admin
). - Enter your username and the new password you just set in phpMyAdmin.
- You should now be able to log in successfully.
Conclusion
You have successfully reset your WordPress password using phpMyAdmin. It’s always a good idea to keep your login details secure and ensure that your email recovery options are updated to prevent needing this method in the future.