7 Common WordPress Login Errors and How to Fix Them

While WordPress is one of the most popular content management systems, you may encounter problems from time to time. For example, you might have issues logging into your WordPress dashboard.

Fortunately, whether it’s a 404 message, redirect loop, or something else, there are multiple ways to fix login errors. By doing so, you’ll make your site accessible again to all members of your content and development team. 

Below, you’ll learn about seven of the most common WordPress login errors. Then, we’ll share our best tips for fixing them. 

1. “Cookies are blocked or not supported” error

Cookies are small snippets of data sent to your browser when you visit certain websites. The cookies are then stored for a specified period or until your session expires.

Websites use cookies to personalize the user experience (UX) by keeping track of your activities and preferences. Additionally, on the WordPress login page, cookies save your login credentials. 

When you log in to WordPress and receive an error message that says, “cookies are blocked or not supported,” there are several potential causes. First, a security or caching plugin might be blocking cookies. Alternatively, if you’ve recently switched web hosts, there may be a conflict between the cookies in your browser and your new server.

There are two main ways to fix this login error. You can either clear your browser cache or edit your wp-config.php file.

Solution 1: Clear your browser cookies and cache 

Clearing your cookies and cache is a great way to free up storage space and resolve common formatting issues and login errors. The process for clearing cookies depends on your browser.

If you’re a Google Chrome user, click on the three dots in the upper-right corner. Then, select More Tools → Clear Browsing Data.

clearing browser cache in Google Chrome

Make sure that at least two of the boxes are ticked: 

  • Cookies and other site data
  • Cached images and files 

Then, confirm the action by clicking on Clear Data. Now, try to re-access your WordPress login page.

Solution 2: Edit your wp-config.php file

If the previous method didn’t work, you’ll need to edit the wp-config.php file via File Transfer Protocol (FTP) or File Manager in your hosting dashboard. 

Once you’ve connected to your site, open its root directory. This is usually labeled public_html. Then, scroll down until you see wp-config.php.

wp-config.php highlighted inside of the file manager

Open the file and scroll down until you see the line that says:

 /* That's all, stop editing! Happy publishing. */

Before that line, paste the following code to fix the blocked or not supported cookies error:


Now, refresh your browser and see if you can access WordPress.

2. WordPress login is stuck in a redirect loop

If your WordPress URL and site address differ from the permalinks registered with your hosting provider, they can create issues with the login procedure. In this case, you’ll be continually redirected back to the WordPress login page without ever gaining access to your site.

A common cause of the redirect loop is a recent migration, like switching hosts or servers. Moving the WordPress core files to a subdirectory can also result in this WordPress error.

As with most login errors, clearing your cookies and cache is the easiest way to start. You can check out the previous section to learn how to do this.

If that doesn’t work, there are three main methods you can try. The first involves editing the wp-config.php file. The second requires editing your functions.php file. Finally, you can try to restore your .htaccess file.

Solution 1: Edit your wp-config.php file

If you still have access to your WordPress dashboard, verify your site address and WordPress address by going to Settings → General. Here, look at your WordPress Address (URL) and Site Address (URL).

updating the WordPress and site addresses inside of the dashboard

These addresses should match up. If they don’t, you can change your settings manually in wp-config.php. This method requires finding and editing wp-config.php via FTP or File Manager. 

Once you’ve gained access to your WordPress files, head to public_html and open wp-config.php in a text editor.

the wp-config.php file circled in green

Now, open the file and paste the following lines of code:

define( 'WP_HOME', 'http://example.com' );

define( 'WP_SITEURL', 'http://example.com' );

You’ll need to substitute your URL for “example.com” in both lines. Then, save your changes and refresh the WordPress login screen to see if the error has cleared. 

Solution 2: Edit your functions.php file

If you’re still unable to log in, you can edit the functions.php file to reset your WordPress address. Again, you’ll need to access the root directory of your site. Then, open your wp-content folder and locate your themes folder.

the Themes folder circled in green

Now, select your active theme and find functions.php.

the functions.php file highlighted in green

Open the file and add the following code to the bottom:

update_option( 'siteurl', 'https://example.com' );

update_option( 'home', 'https://example.com' );

This should update your database and reset your site’s URL. Now, refresh your login screen and try again. Once you’ve gained access to your site, you can delete these lines of code from your functions.php file.

Solution 3: Restore the default .htaccess file

The final fix for the redirect loop is restoring the default .htaccess file. This is because one of the main causes of this error is a corrupted .htaccess file. It may be caused by custom changes you’ve made to the file.

You’ll need to access your WordPress files via FTP or File Manager. Then, locate your .htaccess file.

the .htaccess file circled in green

The first thing to do is to rename the file, so right-click on it and call it “.htaccess-old”. 

Next, you’re going to create a new .htaccess file. Stay within the root directory of your site and click on New File.

creating a new .htaccess file

Name your new file “.htaccess” and paste the following code into it:

# BEGIN WordPress

RewriteEngine On

RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]

RewriteBase /

RewriteRule ^index\.php$ - [L]

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteRule . /index.php [L]

# END WordPress

Save your changes and exit the File Manager. Then, return to the WordPress login page and see if the error is resolved. 

3. “HTTP 500 Internal Server” error

A corrupted .htaccess file can cause internal server errors. Therefore, the best way to resolve the problem is to remove the file altogether.

Solution: Replace the .htaccess file

You’ll need access to your site files. You can do this via FTP or through your File Manager. Then, locate .htaccess within your public_html folder.

the .htaccess file circled in green

It can be a good idea to download a copy of the file to your computer before making any changes. If something goes wrong (or .htaccess isn’t the cause), you can re-upload the file to your database.

Now, right-click on the file to remove it. Additionally, you might need to visit your wp-admin folder to see if there is also an .htaccess file there. If there is, go ahead and delete that too.

Then, head back to your WordPress login screen and try to access your site. If this works, you know that your .htaccess file was the problem. 

In this instance, you’ll need to create a new .htaccess file. You can do this within your root files by following the instructions in Section 2 of this tutorial.

Alternatively, you can generate a new .htaccess file in your WordPress dashboard. To do this, simply navigate to Settings → Permalinks.

updating Permalink settings in WordPress

Then, click on the Save button without making any changes to the settings. You can see if this has worked by revisiting your database and looking for a new .htaccess file in your site’s root directory.

4. “404 Not Found” error

If your site is returning a 404 error, it’s important to check your wp-login.php file. To do this, you’ll need to access your site files via FTP or File Manager. Then, look inside public_html.

If you have a backup of your wp-login.php file, you can compare it against the current one in your database and look for any differences. Essentially, you need to make sure that the file contains these two lines:

fine (‘WP_HOME’, ‘http://example.com’);

fine (‘WP_SITEURL’, ‘http://example.com’);

If you don’t see these lines of code in your wp-login.php file, download a fresh copy of the file from a new WordPress installation

If this doesn’t solve the problem, the 404 error may be due to software conflicts between plugins and themes.

Solution 1: Deactivate your WordPress plugins 

Since you don’t have access to your WordPress dashboard, you’ll need to deactivate the plugins from your server. Access it via File Manager or FTP and locate public_html. Then, find your wp-content folder.

the wp-content folder outlined in green

Open the folder and look for plugins. Then, right-click on the folder to rename it. You’ll want to rename it something like “plugins-old” or “plugins-disabled” to deactivate all plugins on your site. This tricks WordPress into thinking that your plugins no longer exist.

Now, return to your login screen to see if you can access your site. If you can, reactivate each plugin until you find the issue. 

If this is a common issue on your site, it’s worth sticking with reputable plugins from the official WordPress plugin repository. You’ll also want to read customer reviews and see how frequently the plugin is updated. Generally, plugins with active development are best, since you know they’ll be compatible with the latest version of WordPress.

Solution 2: Replace your theme

As we mentioned earlier, the 404 error is generally caused by conflicts within the software on your site. While plugins tend to be the main culprits, the issue may also lie with your theme.

Therefore, you might be able to fix the 404 error by replacing your active theme with a default one.

Since you don’t have access to your WordPress admin area, you’ll need to activate a default theme on your server. 

Access your site’s files via FTP or File Manager. Then, open your wp-content folder and locate your themes folder.

the themes folder outlined in green

Rename the folder something like “themes-old” or “themes-disabled.” If all goes well, this should replace your theme with the latest default version on your website (like Twenty Twenty-Two).

Now, head back to the login page. If you can access your site without seeing the 404 error, you know that your theme was to blame. 

In this case, it might be best to switch themes. Additionally, it’s a good idea to stick with an official WordPress theme. If you’d prefer to use a third-party theme, make sure it comes from a developer or company that you trust.

5. The WordPress login page is a blank screen

The White Screen of Death (WSoD) is one of the most frustrating login errors because it’s challenging to identify its cause. When you trigger this error, all you will see is a blank white screen.

Typically, the WSoD error is related to PHP or database errors. For instance, you may have added an incorrect line of code to one of your site’s files. If you remember making a recent change in your database, it’s a good idea to return to the file and remove the edits. You can do this quite easily by restoring a WordPress backup from just before you made the changes. If this doesn’t work, there are several solutions that you can try.

Start by clearing your cookies and cache. Disabling your plugins and changing to a default WordPress theme can also fix the problem. We explained how to perform these fixes earlier in this troubleshooting guide.

Solution 1: Restore a backup of your site

One of the easiest ways to fix the WSoD error is to restore a backup of your site. With a plugin like Jetpack VaultPress Backup, you can easily back up your database and files.

Jetpack VaultPress Backup homepage

Better yet, you can restore your site from any location, even though you can’t log in. You’ll also be able to view an activity log containing all recent activity on your site. This can help you detect any potential problems.

To restore your site using Jetpack VaultPress Backup, navigate to https://cloud.jetpack.com and open your Activity Log. There, you can either scroll through the events that took place on your site, or use the filters to find a specific one.

Then, click Restore to this point and select the files you want to restore. And that’s it! Simply wait until the restoration process is complete and you’re good to go.

Solution 2: Enable debug mode

The WSoD is notoriously difficult to troubleshoot because you generally don’t receive any information about the error. That’s why it can be useful to enable debug mode, which can identify the specific sources of the error. 

You can enable debug mode using a WordPress plugin like Query Monitor that will do this automatically. Alternatively, you can enable debugging manually by editing your wp-config.php file. 

You’ll need to connect to your site’s server using FTP or File Manager. Then, locate the root directory of your site and look for wp-config.php.

the wp-config.php file outlined in green

Then, find this line at the bottom of the file:

 /* That's all, stop editing! Happy publishing. */. 

Before this line, add the following code to enable WordPress debug mode:

// Enable WP_DEBUG mode

define( ‘WP_DEBUG’, true );

// Enable Debug logging to the /wp-content/debug.log file

define( ‘WP_DEBUG_LOG’, true );

// Disable display of errors and warnings

define(‘WP_DEBUG_DISPLAY’ false );

Now, revisit your site, and you should be able to see new error messages providing information about the cause of the issue.

Solution 3: Increase your server memory

One of the most effective solutions to the WSoD error is to adjust your server’s memory limit. That’s because PHP scripts running on your site may be exceeding the maximum memory provided by your hosting plan and causing the login page to time out. 

You may be able to contact your web host to adjust your memory limits. You can also expand your server memory manually by editing wp-config.php. 

You’ll need to connect to your site using FTP or File Manager. Then, within your public_html folder, find wp-config.php.

In this file, scroll to the bottom and add the following code:

define( 'WP_MEMORY_LIMIT', 'XM' );

Replace “X” with the amount of server memory you want in megabytes. For instance, “128M” will increase this limit to 128 megabytes. 

Save your changes. Then, reload your site. 

If this hasn’t worked, head back to wp-config.php and increase the memory limit even further. But it’s important to note that most web hosts will not let you exceed a certain amount (especially if you’re on a shared plan).

To avoid this type of login error in the future, it’s best to make a new backup of your site before making important changes to its files. Alternatively, it can be a good idea to trial changes on a staging site first. That way, you can test things out in a safe area without affecting your live content.

6. Lost or forgotten passwords

A lost or forgotten password can also prevent you from logging in to your WordPress site. In this scenario, you’ll see a warning message that says, “invalid email address” or “lost your password?”.

You can use the link provided to reset your password. But you might not have access to the email address where your link is sent. In this case, you can fix the login error manually.  

If the error happens to another user (other than yourself) who can’t access your site, you can do this from your WordPress dashboard. As the site administrator, you’re able to create and manage all user accounts. Go to Users in the admin area.

Find and select the specific user who needs their password reset. Then, scroll down to the bottom of the page where it says Account Management.

setting a new password in WordPress

Next, click on Set New Password → Generate Password. At this point, you can either insert a custom password or let WordPress generate one for you. Then, select Update Profile to save your changes, and then share the new credentials with the user. 

7. WordPress login disabled (too many failed attempts)

The last error that we’ll discuss in this article occurs when there have been too many failed attempts to gain entry to your site. Generally, you’ll only see this error message if you have a plugin that secures your WordPress login page.  

For example, you might use a tool that limits your login attempts. Or, you might have a general security plugin installed on your site.

In this case, the only way to fix the login error is to disable the plugin. To do this, you’ll need to access your WordPress site via FTP or File Manager. Then, open your public_html folder and select wp-content.

wp-content folder outlined in green

Next, click on plugins and find the security plugin within the folder. Right-click on the file to rename it. You’ll want to call it something like “example-disabled” to deactivate the individual plugin. 

Head to your WordPress login page and see if you can access your site. If you can, then you’ll need to reactivate your plugin from your WordPress dashboard. You can do this by heading to Plugins → Installed Plugins. Then, find the plugin in question and select Activate.

If this plugin continues to cause WordPress login errors, it’s worth looking for an alternative tool. You can also communicate with the plugin developers to see if they can fix the problem. 

Site backups: The solution to immediately resolve login errors

The best way to avoid login errors is to use Jetpack VaultPress Backup. If anything goes wrong on your site, it’s easy to restore an earlier version or replace individual files.

As a result, you don’t need to work your way through a bunch of troubleshooting steps to find and fix the issue. Instead, you’ll be able to get your site back up and running in no time.

Not only does VaultPress Backup save your site files, but you’ll also get backups of your entire database, along with WooCommerce customer and order data. What’s more, the copies of your site are stored in a secure location across multiple servers, and encrypted for extra peace of mind.

One of the best things about Jetpack VaultPress Backup is that it’s easy to use, making it suitable for even complete beginners. You can create a backup of your site in just a few minutes. Then, you can restore your site using the mobile app

Fix WordPress login errors

While WordPress is a reliable content management system, you may encounter occasional login errors that stop you from accessing your website. Fortunately, you can fix all kinds of WordPress errors like 404 errors, 500 errors, redirect loops, and more.

For example, try increasing your server memory limits if you’re faced with a blank WordPress login screen. Alternatively, you’ll need to remove some code from your wp-login.php file to fix any redirect loops. Meanwhile, if cookies are blocked, it’s worth clearing your browser cache.

This entry was posted in Learn. Bookmark the permalink.

Jen Swisher profile

Jen Swisher

Jen is a Happiness Engineer for Jetpack. She has been working with WordPress and Jetpack for over a decade. Prior to starting at Automattic, Jen has helped small businesses, local non-profits, and Fortune 50 companies create engaging web experiences for their customers. She is passionate about teaching others how to create on the web without fear.

Explore the benefits of Jetpack

Learn how Jetpack can help you protect, speed up, and grow your WordPress site.

Get up to 50% off your first year.

Compare plans

Have a question?

Comments are closed for this article, but we're still here to help! Visit the support forum and we'll be happy to answer any questions.

View support forum
  • Enter your email address to follow this blog and receive news and updates from Jetpack!

    Join 112,023 other subscribers
  • Browse by Topic

  • %d bloggers like this: