WordPress Log In: What To Do When You Can’t Get In
Being locked out of your WordPress log in is one of those things that feels urgent the moment it happens. The site is right there, you can see it, but the admin dashboard is completely out of reach. Before you do anything drastic, most lock-out situations come down to a handful of causes, and most of them have a straightforward fix. This guide walks through each one in plain English, in roughly the order you should try them.
On this page
Wrong Credentials Are the Most Common Cause
This sounds obvious, but it catches more people out than you might expect. WordPress usernames are case-sensitive. If your username is Simon with a capital S, typing simon in lowercase will fail every time. Passwords follow the same rule. Before going any further, check that caps lock is off and that you are typing into the correct field.
Also check that you are pointing at the right login URL. The standard WordPress login page lives at yoursite.com/wp-admin or yoursite.com/wp-login.php. Some security plugins move the login page to a custom address. If that applies to your site, the standard URL will return a 404 page with no explanation.
Try the Password Reset First
If you cannot remember your password, the reset link on the login page is the cleanest route. Click “Lost your password?”, enter your username or the email address on the account, and WordPress sends a reset link. Check your inbox and your spam folder, because it can end up there.
If that email never arrives, the problem is usually with your server’s mail configuration rather than WordPress itself. Many hosting setups do not have outgoing mail configured properly from the start. When that is the case, you need to go a level deeper.
Reset Your Password Through phpMyAdmin
When the email route fails, you can reset your password directly in the database. Log in to your hosting control panel (cPanel or equivalent), open phpMyAdmin, and select your WordPress database.
Open the wp_users table (the prefix may differ if it was changed during setup), find your username, and click Edit. In the user_pass field, select MD5 from the function dropdown and type your new password into the value field. Save the row. That password is now active. Head back to /wp-admin and log in with it.
This feels technical the first time. It is actually a standard procedure, and you are not breaking anything. Think of the database as a very structured spreadsheet and it becomes much less daunting.
Create a New Admin User via FTP
If phpMyAdmin is not available, you can create a fresh admin account by editing a theme file directly over FTP. Connect to your server using an FTP client, navigate to your active theme folder inside wp-content/themes/your-theme/, and open functions.php.
Add the following snippet to the top of the file, just below the opening <?php tag:
add_action('init', function() {
if (!username_exists('tempuser')) {
$id = wp_create_user('tempuser', 'ChangeMe123!', 'temp@yourdomain.com');
wp_update_user(['ID' => $id, 'role' => 'administrator']);
}
});
Save the file, visit any page on your site to trigger the code, then log in with those credentials. Once you are in, go straight to Users, update your original account or create a permanent one, and remove that snippet from functions.php. Do not leave it there. If you want a clearer picture of how WordPress site structure affects security and stability, the technical work happening beneath a WordPress site is often what separates a solid setup from a fragile one.
A Security Plugin May Have Locked You Out
Several security plugins, including Wordfence and Limit Login Attempts, will block an IP address after a set number of failed login attempts. If you have been trying repeatedly and can no longer see the login form at all, this is a likely cause.
To fix it, temporarily disable the plugin via FTP. Go to wp-content/plugins/ and rename the plugin’s folder, for example from wordfence to wordfence-disabled. WordPress deactivates it automatically. Log in, then rename the folder back and reactivate it from the Plugins screen. Your IP should be cleared once you are back inside.
What to Do When a White Screen Appears Instead
A white screen on the login page usually points to a PHP error rather than a credentials problem. This can happen after a plugin update or a PHP version change at the server level.
Enable WordPress debug mode by editing wp-config.php over FTP. Find the line that reads define('WP_DEBUG', false); and change false to true. Reload the page and you should see an actual error message rather than a blank screen, which tells you exactly what needs fixing. Slow or broken admin pages can be a separate matter entirely, and knowing what makes a WordPress site drag helps you rule out performance-related causes quickly.
Before You Start Trying Everything at Once
Some of these fixes need server access that most people do not have close to hand. If your host does not offer phpMyAdmin or FTP access, or if you are on a managed platform with restricted file access, the steps above may not be straightforward. In that case, your host’s support team is the fastest path forward. They can reset credentials at the server level far more quickly than any plugin or workaround.
Getting back in is almost always possible when you can’t login to WordPress. Work through each option methodically rather than trying several things at once. Otherwise it becomes very hard to know what actually fixed it.