I’ve got stuck many times when i forgot my WordPress installation’s admin password. And , the problem becomes a real problem when you don’t have a working mail/SMTP from your WordPress installation ( For e.g.: on local servers). There’s no way to reset the password.
WordPress 2.4 and Below
Prior to WordPress 2.5 , You would’ve easily worked around this issue by going into the MySQL database and doing the following steps.
- Go to phpMyAdmin / MySQL Database manager of your hosting provider.
- Go to the “users” table of the WordPress database.
- Find the user whose password you want to reset.
- Edit the “user_pass” column with md5 hash of your new password. Use MD5 Hash Generator for generating MD5 hash of your password.
WordPress 2.5 +
- Copy the attached file to your WordPress Root ( where wp-config.php file is present ). It is important that it’s in the WordPress directory.
- Access the file via browser.
- Select one or more ( Hold Shift key for selecting multiple users ).
- Type a password ( will be common to all selected users ).
- Hit submit.
- Remove the script file from the root, otherwise anyone can use it and reset your passwords easily.
Reset Wordpress Pass (121.4 KiB)
All of this is done without typing even a single line of code / SQL by you. The script is safe , you can check the code yourself if you want to.