How to Manually Reset Your WordPress Admin Password
WordPress powers millions of websites worldwide, and forgetting the admin password can feel like hitting a dead end. But don’t worry! If you’re locked out, you can manually reset your WordPress admin password quickly and regain access to your site.
At Hitech Technology, a leading web solutions provider in Mumbai, we specialize in WordPress development and troubleshooting. In this guide, we’ll walk you through the steps to reset your admin password manually using simple methods.
Why Resetting the WordPress Admin Password Might Be Necessary
- Lost or Forgotten Password: It happens to the best of us.
- Hacked Website: A compromised password requires immediate action.
- Server Email Issues: If you can’t use the “Forgot Password” option.
- Admin Account Transfer: In cases of changing ownership or handing over to a new admin.
Understanding how to manually reset your password ensures you remain in control of your website under any circumstances.
Steps to Manually Reset Your WordPress Admin Password
Method 1: Reset via phpMyAdmin
- Log in to Your Hosting Control Panel: Most hosts like cPanel provide access to phpMyAdmin.
- Open phpMyAdmin: Navigate to the database associated with your WordPress site.
- Find the Users Table: Look for
wp_users. This is where all user credentials are stored. - Locate Your Username: Identify the row containing your admin username.
- Update the Password Field:
- Click “Edit” next to your username.
- In the
user_passfield, enter a new password and select MD5 from the function dropdown to encrypt it. - Save the changes.
- Log In: Use the new password to log in to your WordPress dashboard.
Method 2: Reset via Functions.php File
- Access Your WordPress Files: Use FTP or your hosting file manager.
- Locate Your Theme Folder: Go to
wp-content > themes > your-active-theme. - Edit the functions.php File:
- Add the following code at the end:
- code:
wp_set_password('YourNewPasswordHere', 1); - Replace
YourNewPasswordHerewith your desired password.
- Save and Upload: Save the file and upload it back to the server.
- Log In and Remove Code: Log in using the new password, then delete the code from the functions.php file to avoid security risks.
Method 3: Use WP-CLI (For Advanced Users)
If you’re familiar with WP-CLI, the command-line interface for WordPress, you can reset the admin password with a single command:
code: wp user update admin --user_pass="YourNewPasswordHere"
Best Practices After Resetting Your Password
Regularly Update WordPress and Plugins: Outdated software can be a gateway for hackers.
Use a Strong Password: Combine uppercase, lowercase, numbers, and symbols.
Enable Two-Factor Authentication: Add an extra layer of security to your login.
Update Email Settings: Ensure your WordPress email configuration works correctly for password recovery.
At Hitech Technology, we pride ourselves on helping businesses in Mumbai and beyond with WordPress solutions that make website management stress-free. If you’re struggling with WordPress or need expert support, contact us today!
