InfoPhilicHow toHow to Reset WordPress Admin Password

How to Reset WordPress Admin Password

Passwords are very important to user accounts, and there may come a time when you need to change your WordPress Admin password. Or, maybe you’ve forgotten it.

There are four ways to reset a lost WordPress admin password. So, in this guide, I will list all the ways to change or rest your WordPress Admin password.

Using the Lost Password option:

WordPress login screen | Lost your password?
WordPress login screen | Lost your password?
  • Open your WordPress administrative login page.
  • Click on the Lost your password? option.
  • It will ask you to input username or email id. Fill out the details and click on Get New Password.
  • Now, Check your email. WordPress will send you with the password reset URL there.
  • Click on it and enter your new strong password.
  • Now, Click Reset Password.

Reset password via phpMyAdmin:

Reset password using phpMyAdmin
Reset password using phpMyAdmin
  • Log into cPanel.
  • Go to Database >> phpMyAdmin.
  • Select the name of your WordPress database and click on the wp_users table.
  • Click on Edit beside your WordPress admin user.
  • In the user_pass field, paste your password.
  • Select MD5 from the drop-down menu.
  • Click on Go.
  • Once done, the page will show you a success message.

Consider reading: Best Guide to WordPress Database Optimization

Via FTP:

  • Login to your website via FTP.
  • Navigate function.php file.
  • In the 2nd line, paste the following command.
wp_set_password('password','admin');

Here, we have set the ‘password’ as a password, and we’re updating it for the user admin.

Note: If you have a different username, you have to mention it in ‘admin’ field.

  • Upload this modified functions.php file back to your /themes folder on the server.
  • Now, log in to your dashboard using the password you set up.
  • Make sure you have removed the wp_set_password line from your local functions.php file. Doing this, WordPress will not reset the password every single time.

Via Emergency Password Reset Script:

WordPress has a PHP script that you can use.

Before using the technique,

  • Make sure, you know your user admin name.
  • It updates the administrator password and sends an email to the administrator’s email address.
  • If you don’t receive the email, the password is still changed.
  • You do not need to be logged in to use it. If you could log in, you wouldn’t need the script.
  • Place this in the root of your WordPress installation. Do not upload this to your WordPress Plugins directory.

How to use the script:

  • Copy & Save the script from Emergency Password Script as a file called emergency.php to the root of your WordPress installation.
  • In your browser, open http://example.com/emergency.php
  • As instructed, enter the administrator username and the new password, then click Update Options. A message is displayed noting the changed password. An email is sent to the blog administrator with the changed password information.
  • Delete emergency.php from your server when you are done. Do not leave it on your server as someone else could use it to change your password.

That’s all, hope these four ways will surely help you in changing or resetting the password. For any kind of assistance, feel free to ask in the comment section below.

See Also:

You'll also like:
Continue to the category
Amit Malewar
Amit Malewarhttps://www.infophilic.com/
Amit Malewar has been the tutorial writer since 2013. His passion for helping people in all aspects of technology flow through the expert coverage he provides. In addition to writing for InfoPhilic, Amit loves to read and try new things.

Comment Policy: Your words are your own, so be nice and helpful if you can. Please, only use your real name and limit the amount of links submitted in your comment. We accept clean XHTML in comments, but don't overdo it please.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

GET STARTED
POPULAR NOW

How to Calibrate battery on your android device

For smartphone users, battery problems are the biggest concern. So to overcome this problem I am writing this short tutorial to calibrate battery. Battery issue...
DEALS

GeneratePress

GRAB THIS DEAL
spot_img