We present you with a handy tutorial on how to create a new password when the Forgotten Password function of WordPress does not work (HS mail server for example) or within the framework of a hacking which would have limited the access of a user account.
User passwords are stored in the MYSQL database of your WordPress site. Let’s where to find them and how to change them.
For this we will have to edit the database. The easiest way is to use PhpMyAdmin. It is generally the tool provided by your host. If this is the first time you connect to it, your host will be able to guide you towards its access.
For your information, if you can’t find the access to the database (name, password…), they can be found in the “wp-config.php” file located at the root of your WordPress site.
Once connected to PhpMyadmin, you will find your database in the left column, if it is not already selected, click on it. You should see the list of tables.
By default, Worpress uses the prefix “wp_” to name the beginning of each table. If this prefix has not been modified, you should find the list of users in the “wp_users” table. If the prefix has been modified then the structure will be “prefixname_users”.
Click on this table to display its contents. It displays all the users of your site.
In the “user_login” column, you will find the names of the users. In the column “user_pass”, you find the password assigned to the user. It is of course encrypted for security reasons.
To change the password, click on “Edit”.
Locate the “user_pass” line on the text field to its right and add your new password.
We must also encrypt it. In the “Function” drop-down list, select “MD5”, then click “Execute” to save.
Your new password is now saved and encrypted! You can go to the WordPress login page to access your site’s administration again.