How to Fix WordPress Login Redirect Loop

If you’re trying to log in to your WordPress dashboard and keep getting stuck in a login redirect loop, you’re not alone. This is a common WordPress issue that prevents you from accessing the admin area.

What is the WordPress Login Redirect Loop?

The login redirect loop happens when you try to log in, but WordPress keeps sending you back to the login page instead of the admin dashboard (/wp-admin/). This endless loop can be caused by:

  • Corrupt or outdated browser cookies
  • Incorrect site URL settings in WordPress
  • Plugin or theme conflicts
  • Issues with .htaccess file
  • Incorrect file permissions
  • Caching problems

How to Fix the WordPress Login Redirect Loop

Follow these methods one by one until the issue is resolved:

1. Clear Browser Cache and Cookies

The most common culprit is corrupted cookies or cache stored by your browser. To fix this, clear all cookies related to your WordPress site, empty your browser cache, and then try logging in again with a fresh session.

2. Check WordPress Site URL Settings

If your WordPress Address (URL) and Site Address (URL) don’t match, WordPress may keep redirecting you to the login page. You can manually correct this by editing the wp-config.php file and adding the following lines with your actual site URL:

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

Save your changes and try logging in again.

3. Disable Plugins via FTP or File Manager

A faulty or conflicting plugin can also cause login loops. To check this, access your site via FTP or File Manager and navigate to /wp-content/plugins/. Rename the entire plugins folder to something else, such as plugins_old, which will deactivate all plugins. If you can log in after doing this, one of your plugins was the problem. Rename the folder back and reactivate them one by one to identify the culprit.

4. Switch to a Default Theme

Themes can sometimes interfere with login functionality. You can test this by renaming your current theme folder inside /wp-content/themes/. WordPress will automatically revert to a default theme such as Twenty Twenty-Five. If you’re able to log in after that, the issue lies with your theme.

5. Regenerate the .htaccess File

A corrupted .htaccess file may be the cause of the login redirect loop. To fix it, rename your current .htaccess file to .htaccess_old and create a new blank .htaccess file in its place. Then paste in the default WordPress rules below:

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

Save the file and check if you can log in again.

6. Check File Permissions

Incorrect file and folder permissions may block WordPress from handling logins properly. Files should typically be set to 644, while folders should be set to 755. You can correct permissions using your FTP client or hosting control panel to ensure WordPress has the right access levels.

7. Disable Caching and Security Plugins

Aggressive caching or security settings can sometimes trap WordPress in a redirect loop. Try clearing your site cache using your caching plugin or hosting tools. If that doesn’t work, temporarily disable any caching or security plugins and see if that resolves the issue.

Leave a Comment