Home MySQL How to Change WordPress Admin Password via phpMyAdmin

How to Change WordPress Admin Password via phpMyAdmin

One undisputed advantage of using phpMyAdmin as a database management and administration frontend is how easy it is to configure and implement user-privileged actions. One such action is resetting your admin password from its Graphical User Interface. Changing user passwords involves several easy steps. We will go through all of them together.

[ You might also like: How to Install and Use phpMyAdmin in Linux ]

Prerequisites

You should have a dedicated database user for your MySQL/MariaDB server. This user should be privileged enough to have access to all your databases and database tables.

It is not advisable to use the root user to gain access to your phpMyAdmin dashboard. If you are familiar with the MySQL/MariaDB command-line, you can use its terminal environment to create an alternatively dedicated database user with a command sequence similar to the following.

$ mysql -u root -p
MariaDB ([none])> CREATE USER 'linuxshelltips_star'@'localhost' IDENTIFIED BY 'Pa55word';
MariaDB ([none])> GRANT ALL PRIVILEGES ON *.* TO 'linuxshelltips_star'@'localhost' WITH GRANT OPTION;

Changing WordPress Admin Password Using phpMyAdmin

The first step is to trace the phpMyAdmin site from your web browser. Accessing phpMyAdmin from a web browser environment requires a user to adhere to the following URL syntax rule.

http:// domain_name_or_IP_address/phpmyadmin

In my case, I am working from localhost and so I will access phpMyAdmin in the following manner.

http://localhost/phpmyadmin

From here, you should be able to comfortably log in to the phpMyAdmin dashboard.

phpMyAdmin Login
phpMyAdmin Login
phpMyAdmin Dashboard
phpMyAdmin Dashboard

On the left side of the phpMyAdmin environment, you should see a list of all the MySQL/MariaDB databases that can be manipulated by your privileged database administration powers.

Trace the database associated with your WordPress site and click on it to expand.

phpMyAdmin Databases
phpMyAdmin Databases

The above clickable action should reveal all the database tables associated with the main WordPress database. It is a common rule for WordPress to label or name its database tables with the prefix “wp_”.

On the above exposed WordPress database table list, trace the one with the naming convention “wp_users” and click on it. It is the WordPress database table that holds all site user’s credential information.

List WordPress Users in phpMyAdmin
List WordPress Users in phpMyAdmin

The above action should list different database users associated with WordPress’ wp_users database table. Take note of these users’ IDs. In the above screen capture, the two users’ ID entries are 1 and 3 respectively.

Gaze back at phpMyAdmin’s dashboard panel on the left. Trace the WordPress database table with the naming convention wp_usermeta and click on it. It should reveal some interesting information.

List WordPress Users Information
List WordPress Users Information

The wp_users ID should match with wp_usermeta user_id. Also, the wp_usermeta user_id values should be on the same row with wp_capabilities and a:1:{s:13:"administrator";b:1;} values.

This reference match confirms that the wp_users’ users whose password we want to change are indeed admin users. If these wp_users ID to wp_usermeta user_id row values reference did not exist, we would only be changing the password of an ordinary WordPress user and not the one for an Admin user.

We can now go back to the wp_users WordPress table and fulfill the objective of this article.

Edit WordPress User Table
Edit WordPress User Table

Click Edit on the Admin user whose password you need to change. Under the ID table column, find user_pass and set the varchar(255) value to MD5, and then key in your new Admin user password value. Finally, click [Go].

Change WordPress Admin Password
Change WordPress Admin Password

The below screen capture confirms that the query execution was a success.

WordPress Admin Password Change Confirmation
WordPress Admin Password Change Confirmation

You should now be able to log in back to your WordPress site with the new password.

New WordPress Login
New WordPress Login
New WordPress Dashboard
New WordPress Dashboard

A good thing about using the phpMyAdmin dashboard to change Admin user-associated login credentials is that it is fast and flexible. You do not have to worry about typos unlike when executing queries on MySQL to change WordPress passwords.

Ravi Saive
I am an Experienced GNU/Linux expert and a full-stack software developer with over a decade in the field of Linux and Open Source technologies. Founder of TecMint.com, LinuxShellTips.com, and Fossmint.com. Over 150+ million people visited my websites.

Each tutorial at UbuntuMint is created by a team of experienced writers so that it meets our high-quality standards.

Was this article helpful? Please add a comment to show your appreciation and support.

Got something to say? Join the discussion.

Thanks for choosing to leave a comment. Please keep in mind that all comments are moderated according to our comment policy, and your email address will NOT be published or shared. Please Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.