How to Log Into Drupal 7 & Retrieve Lost Password
You can log in to your Drupal website by going to:
Be sure to replace exampledomain.com with your domain name.
If Drupal was installed on the primary domain and pretty URLs was previously enabled, you also can use the following URL:
If Drupal were installed in a folder instead, you would need to add the folder's name to the URL, like so:
Once there, enter your username and password.
Request a New Password
If you have forgotten your Drupal password, the easiest way to regain access is to use the new password feature built into Drupal.
- Click on the Request new password tab on the login page.
- Enter your email address or Drupal username, and then click on the E-mail new password button.
The page will refresh and display the following message:
- Check your email for your replacement login information.
- Click on the link in the email. This link can only be used once.
- Once on the page, click on the Log in button.
- Enter a new password in the fields provided.
- Click the Save button. The page should refresh and display the following message:
You are now logged in to Drupal 7. Be sure to use the password you just set to log in in the future.
Manually Resetting Your Password
Unlike WordPress and some other scripts, you cannot reset the password directly in the database; instead, you have to change the email to one that works and then reset the password via Drupal's request new password feature.
If you did not get the email or the email you specified for that username is no longer valid, it is possible to manually change the email address in the database so that you may request a new password. You would need access to your cPanel for this.
Step 1: Figuring Out Which Database
Before changing your email address in the database, we will need to locate the Drupal database. If you only have one database, one Drupal installation, or you already know the name of the database or think you can figure it out easily, then skip to step 2.
Follow these steps to find out the database.
- Log in to cPanel.
- In the Files section, click on the File Manager icon.
- Locate the Drupal installation in the file system. If you installed Drupal in the main folder of the primary domain, you should already be looking at the Drupal files.
- If you installed it in a subfolder or an addon domain, you would need to navigate to the appropriate folder. You can use the list of folders on the left or use the files and folders in the middle/right. (As an example, if you installed Drupal in the drupal7 folder, you would double-click on the blue folder icon next to drupal7 in the middle/right. That would take you inside the folder and show you Drupal's files.)
- Double-click on the folder for sites.
- Double-click on the folder for default.
- Right-click on the file settings.php and then select Edit.
- A dialog box will pop up called Code Editor. Click the Edit button.
- Ignore any gray lines beginning with an asterisk (*) as this indicates the line is a comment.
- Scroll down until you find the line that says something similar to:
,where user_drp71 would be whatever your database name is. Write down or remember this database name, as you will need it in the next step.
- You can then close the code editor and close the file manager—no need to save anything since nothing should have been changed here.
Step 2: Fixing the Email Address
To manually change your email address in the database so you can reset your password, please follow these steps:
- Go back to the cPanel.
- In the Databases section, click on the phpMyAdmin icon. This will open phpMyAdmin in another window or tab.
- Find the database in the left column and click on its name.
- Navigate on the right side of the screen to find the user's table in the list of tables.
- Immediately to the right of the table drupal_users, click on the Browse button.
- Find the username you want to reset in the list of users. If you have a lot of users, expect to navigate multiple pages to find the user you want.
- Click on the Edit icon next to the user you want to reset the password for.
- Locate the mail category in the first column. Next to mail, you will see the email that is currently set for this user.
- Change the email address to a valid working email address.
- Click the Go button near the bottom of the page.
- Follow the directions in the Request a New Password section for requesting a new password.