WordPress

How to Reset Your WordPress Admin Password via phpMyAdmin

Being locked out of your own WordPress site is stressful, especially if the password-reset email never arrives. When email is not an option, you can set a new password directly in the database using phpMyAdmin. It sounds technical, but it is only a few careful clicks.

Before you begin: take a quick backup. You are editing the database, so a safety net is wise.

Step 1: Open phpMyAdmin

  1. Log in to cPanel and open Databases → phpMyAdmin.
  2. In the left panel, click your WordPress database. Not sure which one? Check the DB_NAME line in your site’s wp-config.php file.

Step 2: Find your user

  1. Open the wp_users table (the prefix may differ, e.g. wp_).
  2. Find your username and click Edit on that row.

Step 3: Set the new password

  1. Locate the user_pass field.
  2. In the Function dropdown next to it, choose MD5 — this encrypts your new password (WordPress upgrades it automatically on your next login).
  3. In the value box, type your new password, replacing the existing scrambled text.
  4. Click Go to save.

Now log in at yourdomain.com/wp-admin with your new password.

Frequently asked questions

Why not just use “Lost your password?”

Use that first if you can — it is easier. This method is for when reset emails do not arrive, often due to an email sending problem on the site.

My reset emails never arrive. Can I fix that?

Yes — configure WordPress to send mail properly via SMTP so future resets work. It is a common fix worth doing.

I still cannot log in after resetting.

Double-check you edited the right database and selected the MD5 function. If login loops or errors, see the white screen of death guide or contact support.

Was this article helpful?