How to Fix the "Too Many Redirects" Error in WordPress
You try to open your WordPress site and the browser shows "This page isn't working — yourdomain.com redirected you too many times" (or "ERR_TOO_MANY_REDIRECTS" in Chrome). Instead of loading your site, the browser detected an infinite loop: page A sends you to page B, which sends you back to page A, over and over until the browser gives up.
I first ran into this error years ago after switching a client's site from HTTP to HTTPS. The SSL certificate was installed, but the WordPress settings and the server configuration were fighting over which protocol to use — creating an endless redirect loop. It took me an hour to figure out back then. With this guide, you can fix it in 5 minutes.
What Causes the Too Many Redirects Error?
A redirect loop happens when two or more redirect rules conflict with each other. The most common causes in WordPress are:
- Misconfigured WordPress URL settings — The WordPress Address (URL) and Site Address (URL) in your settings do not match, or they use different protocols (one uses http://, the other uses https://).
- SSL/HTTPS conflict — Your server forces HTTPS, but WordPress is configured for HTTP (or vice versa). The server redirects to HTTPS, WordPress redirects to HTTP, and the loop begins.
- Faulty .htaccess rules — Manual redirect rules or rules added by plugins create a conflicting loop.
- Plugin conflict — A caching plugin, SSL plugin, or redirect plugin adds rules that conflict with your server configuration.
- Cloudflare SSL mode mismatch — If you use Cloudflare, the SSL mode must match your server configuration. Using "Flexible" when your server also forces HTTPS creates a redirect loop.
- Stale browser cookies — Old cookies can contain redirect information that creates a loop even after you have fixed the underlying issue.
Step 1: Clear Your Browser Cookies
Before troubleshooting, clear your browser cookies for your domain. Old cookies sometimes contain redirect paths that create loops even after the server-side issue is fixed.
In Chrome:
- Click the padlock icon (or "Not Secure" text) in the address bar.
- Click "Cookies and site data".
- Click "Manage on-device site data".
- Delete all cookies for your domain.
In Firefox:
- Click the padlock icon in the address bar.
- Click "Clear cookies and site data".
After clearing cookies, reload the page. If the error is gone, you had stale cookies. If the error persists, continue to the next step.
Step 2: Check WordPress URL Settings
The WordPress Address and Site Address must match. If they do not — for example, one uses http:// and the other uses https://, or one includes www. and the other does not — WordPress creates a redirect loop.
If you can access your WordPress dashboard, go to Settings → General. Check the two URL fields:
- WordPress Address (URL):
https://yourdomain.com - Site Address (URL):
https://yourdomain.com
Both fields should be identical — same protocol (http or https), same domain, and same www/non-www format.
If you cannot access the dashboard (because the redirect loop blocks it), you need to fix these values directly in the database:
- Log in to your hosting control panel and open phpMyAdmin.
- Select your WordPress database from the left sidebar.
- Open the
wp_optionstable (the prefix might be different — checkwp-config.phpfor$table_prefix). - Find the rows where
option_nameissiteurlandhome. - Make sure both
option_valuefields are identical and use the correct protocol.
Alternatively, you can force the URLs in wp-config.php. Add these lines above "That's all, stop editing!":
define('WP_HOME', 'https://yourdomain.com');
define('WP_SITEURL', 'https://yourdomain.com');
This overrides the database values. Replace https://yourdomain.com with your actual URL (including the correct protocol).
Step 3: Reset Your .htaccess File
A common cause of redirect loops is conflicting rules in the .htaccess file. A plugin might have added a redirect rule that conflicts with another redirect on the server.
- Connect to your site via FTP.
- Rename
.htaccessto.htaccess_backup. - Create a new
.htaccessfile with just the default WordPress rules:
# BEGIN WordPress
<IfModule mod_rewrite.c>
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]
</IfModule>
# END WordPress
Save and reload your site. If the redirect loop is gone, the old .htaccess had conflicting rules. If you need HTTPS redirection, add it properly:
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
Place this above the WordPress rewrite rules. Do not add HTTP-to-HTTPS redirects if your hosting panel or Cloudflare already handles this — that is what creates the loop.
Step 4: Fix Cloudflare SSL Settings
If you use Cloudflare (and you should — see my Cloudflare setup guide), the SSL mode must match your server configuration. This is one of the most common causes of redirect loops I see.
The problem: Cloudflare's "Flexible" SSL mode means Cloudflare connects to your server over HTTP. If your server also has a rule to redirect HTTP to HTTPS, you get an infinite loop: Cloudflare sends HTTP → server redirects to HTTPS → Cloudflare receives HTTPS and sends HTTP again → server redirects again → infinite loop.
The fix:
- Log in to your Cloudflare dashboard.
- Go to SSL/TLS → Overview.
- Set the encryption mode to "Full" or "Full (Strict)".
- Full: Cloudflare connects to your server over HTTPS but does not validate the certificate. Use this if you have a self-signed certificate.
- Full (Strict): Cloudflare connects over HTTPS and validates the certificate. Use this if you have a proper SSL certificate from your host (which you should). This is the recommended setting.
After changing the SSL mode, go to SSL/TLS → Edge Certificates and make sure "Always Use HTTPS" is turned on. Then purge Cloudflare's cache: Caching → Configuration → Purge Everything.
Step 5: Disable Plugins That Handle Redirects
Several types of plugins can cause redirect loops:
- SSL plugins (Really Simple SSL, WP Force SSL) — They add redirect rules that can conflict with your server's existing HTTPS redirect.
- Caching plugins (WP Super Cache, W3 Total Cache, LiteSpeed Cache) — They sometimes serve cached redirect responses.
- Redirect plugins (Redirection, Safe Redirect Manager) — They add custom redirect rules that can create loops.
- SEO plugins — Some SEO plugins add canonical redirects (www to non-www, etc.) that can conflict.
If you can access the dashboard, deactivate these plugins one at a time and test after each deactivation. If you cannot access the dashboard, rename the plugin folders via FTP to disable them.
Step 6: Check for Server-Level Redirects
Sometimes the redirect loop is caused by a server-level configuration, not WordPress. This is common when:
- Your host forces HTTPS at the server level AND you have a redirect in .htaccess.
- Your host forces www AND you have a redirect to non-www (or vice versa).
- There is a redirect in an Nginx configuration file that conflicts with WordPress.
To check, use a redirect checker tool like httpstatus.io. Enter your URL and it will show you the entire redirect chain — exactly which URLs are redirecting to which, and which status codes they use (301, 302, etc.). This makes it easy to spot where the loop starts.
You can also check redirects using Chrome DevTools:
- Open Chrome DevTools (press
F12). - Go to the Network tab.
- Check "Preserve log" (so redirects are not cleared).
- Reload the page.
- Look at the list of requests. Each 301 or 302 response is a redirect. Click on each one to see the "Location" header, which shows where it redirects to.
Preventing Redirect Loops
- Use one method for HTTPS redirects. Pick either .htaccess OR your hosting panel OR Cloudflare — not all three. Multiple layers of HTTPS redirects are the #1 cause of this error.
- Keep WordPress URLs consistent. Make sure the WordPress Address and Site Address in Settings always match your actual domain and protocol.
- If using Cloudflare, use Full (Strict) SSL. Never use "Flexible" if your server has an SSL certificate — it will create a redirect loop.
- Test after making URL changes. After changing SSL settings, permalink structure, or domain configuration, always test in an incognito browser window (which has no cached cookies or redirects).
The "Too Many Redirects" error is almost always a configuration mismatch — two systems disagreeing about where to send traffic. Once you identify which two rules are conflicting, the fix is straightforward. For more troubleshooting help, see my full guide to common WordPress errors.
Written by Marvin
Our team tests and reviews WordPress products to help beginners make confident choices.
Learn more about our team →You might also like
How to Fix the 500 Internal Server Error in WordPress
The 500 Internal Server Error tells you nothing useful — just that something broke. I walk through the most common causes and the exact steps to fix each one, from .htaccess to plugin conflicts.
postCommon WordPress Errors and How to Fix Them (Complete Guide)
WordPress errors are frustrating but rarely fatal. I cover the 11 most common WordPress errors with quick-fix solutions for each one — based on years of troubleshooting real sites.
postHow to Fix the WordPress Memory Exhausted Error
Seeing "Fatal error: Allowed memory size of X bytes exhausted"? I explain why this happens and show you 4 ways to increase the WordPress memory limit — with exact code snippets for each method.
postHow to Fix "Error Establishing a Database Connection" in WordPress
Seeing "Error establishing a database connection" on your WordPress site? I walk through every cause and fix — from wrong credentials in wp-config.php to corrupted databases and server issues.