Reset Drupal administrator password
If you want to change your Drupal website administrator password, you can follow the steps below:
- Login to cPanel and click the Databases > phpMyAdmin option.
- Select the database that's used by your Drupal website from the drop-down menu on the left.
- Then click the SQL tab and type the following SQL code at the text box:
update users set pass=md5('NEWPASS') where uid = 1;
- Change the "NEWPASS" with the new preferred password. The uid is the user id for whom the password will be updated. The user id 1 is the first user of the system and that is the administrator, but it would be good to check that first and make sure that the id=1 belongs to the user you want to edit. If you are not sure about the user id you can follow the alternative option below to avoid any mistakes.
- Finally click the GO button and the Drupal administrator password will change.
Alternatively also for greater security you can:
- Browse the users table through phpMyAdmin.
- Find the user record that you want to edit and click the Edit button.
- At the password field type the new password and select MD5 from the Select List option, so the new password will be saved as encrypted.