Home / Web Development / How to Reset WordPress Admin Password with phpMyAdmin

How to Reset WordPress Admin Password with phpMyAdmin

I saw a person the other day on a forum asking how to reset WordPress admin password without access to the email account they used to register. Although this is a very rare situation, this does happen to lot of people. So I decided to write a tutorial and create a video showing how to recover lost WordPress admin password without access to the email address.

WordPress gives you an option to reset forgotten password through the login page. But you must have access to the email account you used to create your WordPress admin account. If you have access to the email, you can easily reset your password. But what if you no longer have access to the email account you used? or what if the password reset email doesn’t reach your email inbox for some reason? you could be locked out of your own website.

Well, don’t lose hope. If you have access to your cPanel, resetting WordPress admin password is easier than you think. Your password, as well as all other valuable information are stored on the site’s MySQL database. If you can access MySQL database for the site, you can change anything on your site without even logging into WordPress. In this case, the admin password.

Step-by-step guide to reset WordPress admin password with phpMyAdmin

Let’s start by login into cPanel. You should know the name of MySQL database used for your website. This information is stored in the wp-config.php file in your public_html folder. Use cPanel file manager to view this file if you don’t remember the database name. And this is not necessary if you only have one database on your account. Let’s reset the admin password.

  1. Login to phpMyAdmin: Once on the cPanel, scroll down to databases section and click phpMyAdmin icon. You’ll be redirected and automatically logged into phpMyAdmin. If auto login failed for some reason and you’re asked to enter a username and a password, enter those credentials on wp-config.php file.
  2. Edit wp_users table: Information about all registered users on your website are stored on the wp_users table. So select the database from left sidebar and click wp_users link. You’ll land on a page that lists all registered users on your website. Click on the edit link related to your account.
  3. Change Password: The page that loads next will include all information of your account. You only need to edit user_pass raw. Select the function as MD5 and add your new password as the Value. Click Go from the bottom of the page to save the changes.
  4. Login with new Password: Now open your website with your favorite browser and login to your account with the new password.

Following these four easy step should give back access to your WordPress admin account. This method can be also used to reset password for any user on your website and you can also change your admin email address with it. Hope this article and video helped you reset forgotten WordPress admin password without access to the email account. Feel free to ask any questions on the comments section.

namecheap namecheap

About Tharindu Kumara

Profile photo of Tharindu
Hey!! I'm Tharindu. I'm from Sri Lanka. I'm a part time freelancer and this is my blog where I write about everything I think might be useful to readers. If you read a tutorial here and want to hire me. send me a message on Fiverr.

Leave a Reply