From this tutorial you’ll learn how to change WordPress Dashboard access details. It will help you to reset your password in the case you’ve lost it. There are several ways to do it. You can reset login credentials using phpMyAdmin tool, Emergency Password Reset script or WordPress user reset password function. Feel free to use one of these methods.
Resetting Password Using phpMyAdmin Tool
- First, let’s enter your hosting server cPanel and access phpMyAdmin tool.
- Here select your WordPress website database and locate wp_users table. Click on it to open.
- Find your username in the user_login and click on Edit to access the password details.
- Select MD5 in the user_pass line.
- Select the list of digits and characters in the Value block and delete it. Here you need to fill in your new password.
- Click on Go button in order to save the changes.
- As a result, you’ll be able to enter WordPress Dashboard using your new login credentials.
Resetting Password Using Special Script
- First, let’s create an emergency.php file. Open the code editor that is convenient for you (e.g., Notepad++, Sublime, etc.) and click on File tab in the top left corner. Here select New option to create a new file.
Add the following code to the file. - Now you need to select the language to use for the file. In the Languages tab from the top panel choose PHP. Then navigate to File tab and save it to your hard drive.
Open your hosting server cPanel and navigate to File Manager tool. Here you need to open your WordPress root folder and upload the emergency.php file to the server. - Paste http://your_site.com/emergency.php URL address in your browser address bar. Enter the username and the new password, and click on Update Options.
- You’ll receive an email message with your new administrator password on your administrator email.
- Now you can log in to your website using your new password.
Note, that after you’ve retrieved the password, you need to delete the emergency.php file from your server to secure your website.
Resetting Password Using WordPress User Reset Password Function
- First, you need to access your hosting server through FTP connection. Use Total Commander or Filezilla file manager tool.
- Navigate to wp-content/themes/theme-name directory and download functions.php file to your hard drive.
- Add the following lines of code in the very beginning of the file, just after <?php.
- Note, that you need to replace “1” with your actual user ID number in the wp_users table. You also have to replace password with a new password you want to set.
- Save the changes and upload the file back to your hosting server.
- As a result, you’ll be able to login using your new password.