When surfing the web, we’ve all likely stumbled upon a “too many redirects” error message. This can be frustrating for users — and downright scary for site owners. You don’t want this error message to get in the way of theuser experienceor conversions on your site.
In this post, we’ll go over what this error means and how to fix it on different browsers so you can get your site back up and running.
Too Many Redirects Error
The too many redirects error indicates that your browser is stuck in an infinite redirection loop. That means your browser is trying to visit one URL which points to another URL, which points back to the first URL, so it’s stuck. This loop could go on forever — but eventually your browser gives up and displays the “too many redirects” error.
This error might show up differently depending on what browser you’re using. Here are some variations below.
Too Many Redirects Chrome
Too Many Redirects Safari
Too Many Redirects Firefox
This error is likely caused by a configuration error on the website you’re trying to visit. If the website in question is your website, then you have to take steps to resolve it as soon as possible. Let’s walk through solutions below.
How To Fix Too Many Redirects
- Clear cookies on the redirecting website.
- Clear your browser cache.
- Ensure your SSL certificate is installed correctly.
- Evaluate your third-party services and plugins.
- Reset your htaccess file.
- Contact your hosting provider.
These steps apply to any website, no matter whatwebsite builderorcontent management system (CMS)it uses.
However, if you have a WordPress website, then there are some unique steps you can take to resolve the too many redirects error. Check outHow to Fix the Redirect Loop Error in WordPressto learn more.
1. Clear cookies on the redirecting website.
To start, try clearing cookies on the website causing the redirect loop. The process is similar for any web browser. The steps for each are outlined below.
Chrome
- At the top right, click theCustomizeicon then clickSettings.
- ClickPrivacy and securityfrom the left toolbar.
- ClickCookies and other site data.
- Scroll down and clickSee all cookies and site data.
- At the top right, search for the website's name.
- To the right of the site, clickRemove.
Safari
- ClickSafari>首选项.
- ClickPrivacy.
- ClickManage Website Data.
- Use the Search field to find the name of the website causing the redirect loop.
- Select the site and clickRemove.
- ClickDone.
Firefox
- ClickFirefox>首选项.
- ClickPrivacy & Securityfrom the left toolbar.
- Scroll to theCookies and Site Datasection.
- ClickManage Data…
- In the Search field, type the name of the website causing the redirect loop.
- ClickRemove All Shown.
- ClickSave Changes.
2. Clear your browser cache.
If clearing cookies on the specific website causing the redirect loop doesn’t work, try clearing your whole browser cache. The process is similar for any web browser. The steps for each are outlined below.
Chrome
- At the top right, click theCustomizeicon then clickSettings.
- ClickPrivacy and securityfrom the left toolbar.
- ClickClear browsing data.
- Set your time range, then clickClear Data.
Safari
- ClickSafari>首选项.
- ClickPrivacy.
- ClickManage Website Data.
- ClickRemove All.
- ClickRemove Now.
- ClickDone.
Firefox
- ClickFirefox>首选项.
- ClickPrivacy & Securityfrom the left toolbar.
- Scroll to theCookies and Site Datasection.
- Click清除数据……
- Cookies and Site Data and Cached Web Content should both be check marked by default. ClickClear.
3. Ensure your SSL Certificate is installed correctly.
If you’ve cleared your cookies and cache and are still getting the too many redirects error, then the issue could be your HTTPS settings. HTTPS means that your website uses a security protocol called安全套接字层(SSL)to encrypt data transfers between a browser requesting a website and the web server delivering that website.
This protocol can cause the redirect loop in special circumstances. For example, if you’veforced SSL on your sitewithout actually installing an SSL certificate, then you’ll likely see the error. That’s because all requests to your hosting server are sent over HTTP, which your server has to redirect to HTTPS again and again.
So it’s important to ensure your SSL certificate is installed correctly andrenewedwhen needed. You can use an online tool likeSSL Shopper,SSL Server Test, orDigicert, to test that your SSL configuration is installed, valid, and trusted in just a few minutes.
4. Evaluate your third-party services and plugins.
If you’ve ruled out your cookies, cache, and HTTPS settings as causing the too many redirects error on your site, then check any third-party services you use.
If you use a proxy server — an intermediary server that directs requests from multiple clients to different servers —then it could be causing the error message. For example,Cloudflarehas a Flexible SSL option, which forces requests between clients and Cloudflare to be sent over HTTPS but allows requests between Cloudflare and your origin server to be sent over HTTP.
If that option is enabled but you already have an SSL certificate installed on your server, then your server will redirect these requests to HTTPS and likely cause the too many redirects error. You can resolve this issue by switching to another encryption mode, like Full or Full (strict).
If your site is on WordPress, then third-party plugins could also be causing the error.Redirect pluginsallow you to easily and quickly set up redirects when the permalink of a post or page is changed or when other conditions are met. But sometimes changing the settings of these plugins or updating them can cause the too many redirects error.
To see if this is the issue on your site, try disabling your插件. A good way to test this is by deactivating all your plugins in bulk, then reactivating them one by one to isolate the culprit. Here are the steps:
- Log into your WordPress admin dashboard.
- SelectPlugins>Installed Plugins.
- Check the box next toPluginto select all your plugins.
- ChooseDeactivatefrom the Bulk Actions drop-down menu, then clickApply.
- Refresh your site.
If you no longer see the too many redirects error, start activating each plugin one by one and reloading your website after each activation to identify the faulty plugin.
You may need to reach out to the plugin developer to resolve the issue, or find an alternative to use on your site.
5. Reset your htaccess file.
If none of the steps above have resolved the too many redirects error, then the problem is likely how redirects are set up on your server. To double check that, you’ll need to access yourhypertext access file, or the .htaccess file, rename it, and create a new one. To do so, you can use a file manager likecPanelor viaFTP client. The following steps are for cPanel specifically.
- Go toFile Managerand select your .htaccess file.
- Right-click to rename it .htaccess_old. This is now your backup file.
- Go topublic_html
- Create a new text file and name it .htaccess.
- Copy and paste the following code into the file.
< IfModule mod_rewrite.c >
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
- You can now save and exit File Manager.
This will reset the .htaccess file to its default settings so you can now save and refresh your site. If this hasn’t solved the too many redirects error, you can restore the backup .htaccess file.
6. Contact your hosting provider.
If none of the steps above resolve your issue, then try contacting your hosting provider. If you let them know you’re experiencing a too many redirects error that's affecting yourwebsite performance, they might let you know what the exact cause is — or even fix it for you.
Resolving the Too Many Redirects Error
There’s no foolproof method for preventing a too many redirects error, but there are steps you can take to resolve it. By fixing this errors as quickly as possible, you’ll ensure visitors can continue browsing, navigating, and converting on your site with ease.
Originally published Oct 12, 2021 7:00:00 AM, updated October 12 2021
Topics:
Website PerformanceDon't forget to share this post!
Related Articles
Expand Offer
Sign up for HubSpot's CMS Software
Get it now