This article describes to manually reset the WordPress administrator password in the database. Normally if you forget your password, you can use the WordPress password recovery feature to reset the password by e-mail. However, if this option is unavailable you can reset the password in the database manually.
Resetting the WordPress Admin password through the database:
Step 1: Login your cPanel using appropriate username and password.
Step 2: In the Databases section of the cPanel home screen, click on the phpMyAdmin feature.
Step 3: Now choose the respective WordPress database that is associated with the site. Now the list of tables in the database will appear.
Step 4: On the top menu bar, click SQL.
Step 5: Copy and paste the following statement into the SQL query text box. Replace new_password with the new password, and replace admin_username with the administrator’s username.
Code:
UPDATE `wp_users` SET `user_pass` = MD5( 'new_password' ) WHERE `wp_users`.`user_login` = "admin_username";
Step 6: Once the above code executed successfully, Click Go and then update the database with the new password in phpMyAdmin.
Step 7: Now you will be able to log in to WordPress as the administrator by using the new password.