How to Change WordPress Admin Password via Database

  • Author: Meghna Meghwani
  • Published: 16 July 2025
  • Last Updated: 16 July 2025
How to Change WordPress Admin Password via Database

Table Of Contents

Change WordPress Admin Password easily if you’ve forgotten it, yes, it can be frustrating, but there’s a simple solution. You can reset your password directly through the database in just a few steps. This guide is quick, simple, effective, and easy to follow.

Why Change WordPress Admin Password from Database?

Sometimes, you can’t access the reset email link. Or maybe your site’s email function is broken and not working. In such cases, changing the password directly from the database is the fastest solution.

We can easily change the WordPress Admin Password by using “PHPMyAdmin”. If you are using any cloud hosting or management platform like ServerAvatar, it is very easy to access PHPMyAdmin directly from ServerAvatar Dashboard.

First, log in to ServerAvatar Dashboard, and create PHPMyAdmin application for changing the WordPress Admin Password.

Step 1: Open phpMyAdmin

It is very easy and straight-forward process to change WordPress Admin Password using PHPMyAdmin application. phpMyAdmin is where you can view and edit your WordPress database tables.
You can directly create PHPMyAdmin through the ServerAvatar panel.

  • Navigate to your server panel and click on Applications section from the left-hand sidebar. 
  • Click on the “Create an Application” button.
Application Dashboard

Fill out the form for creating the application:

  • Enter your “Application Name”
  • Select the domain from Primary and Test Domain (as ServerAvatar providing test domains to create application without using your own domain)
  • Enter the “Domain Name”
  • Select the method as “One Click”
  • Select the “PHPMyAdmin” application from the given options 
  • Click on the “Create Application” button.
One click App Deployed
  • Once your PHPMyAdmin application is created, open PHPMyAdmin by using the application URL. 
  • Login to PHPMyAdmin application using your database Username and Password.
phpMyAdmin
  • It opens the database management interface as shown in the image below.
phpMyAdmin database

Step 2: Select Your WordPress Database

In the left sidebar, find the correct database of your application. If you are unsure, open and check your site’s wp-config.php file, and look for this line:

PHP
define( 'DB_NAME', 'your_database_name' );

If you hosted your application from ServerAvatar, you can directly check out  wp-config.php file by navigating to the “File Manager” from left-hand sidebar of your application panel. 

  • Go to the public_html directory, and open the wp-config.php file. 
File Manager
  • You can findout the Database name mentioned in the wp-config.php file.
Wp-Config File

Select that particular database in phpMyAdmin.

Step 3: Find the Users Table

Now locate the table named wp_users (or similar, depending on your table prefix).

  • Click on wp_users.
  • A list of all users will appear.
  • Find your admin username in the list.
Change User Name

Step 4: Edit the Admin User

Next to your admin username:

  • Click Edit (the pencil icon).
  • You’ll see editable fields for that user.
  • Locate the user_pass field.
Edit Admin User


Step 5: Change the Password Using MD5

In the user_pass field:

  • Remove the current mentioned password.
  • Type your new password in the field.
  • In the Function dropdown, select MD5. This step encrypts your password correctly for WordPress.
  • Click Go at the end of the page to save.
Change WordPress Admin Password

Step 6: Login to Your WordPress Dashboard

  • Navigate to your WordPress website’s login page: https://yourdomain.com/wp-admin
  • Enter your username and new password. 
  • You will now have access to the dashboard again using new password.

Important Security Tips

After changing your password:

  • After login to wp-admin, go to Users > Edit for your admin user and update your password again from WordPress dashboard. WordPress now uses better hashing than MD5.
Set New Password
  • Install a security plugin like Wordfence or iThemes Security.
  • Always keep regular backups.
  • Use strong passwords and enable 2FA.

Conclusion

Resetting your WordPress admin password via phpMyAdmin is a quick and reliable method, especially when email recovery fails. With platforms like ServerAvatar, accessing phpMyAdmin and managing your database becomes even more effortless. By following the simple steps mentioned above, you can regain access to your dashboard in minutes. Just don’t forget to update your password again from the WordPress dashboard for stronger security. Keep your site safe with regular backups, a strong password, and essential security plugins.

Keep this guide handy for emergencies. Secure your login right away and avoid future lockouts. It only takes a few clicks inside phpMyAdmin.

FAQs

Q1. Is it safe to change the password from phpMyAdmin?

Yes, but make sure you use MD5 Function and change it again inside WordPress for better encryption.

Q2. What if I don’t see wp_users table?

Your table prefix may be different. Look for “_users” at the end of table names.

Q3. Can I reset the password without cPanel?

Yes, if you have database access via another panel like Plesk or DirectAdmin.

Q4. Why use MD5?

WordPress expects the password in MD5 format when inserted via phpMyAdmin.

Ready to Transform Your Hosting?

Join 1,000+ developers who’ve simplified server management with ServerAvatar. Get started for free and deploy your first server and application in minutes.
  • No Credit Card Required
  • Free $10 Server Credits
  • Deploy in next 10 minutes!