Ошибка too many redirections safari

Safari не удается открыть страницу из-за большого количества переадресаций — что делать

В браузере Safari на iPhone и iPad нередко проявляется неприятная проблема, которая не позволяет пользователям получать доступ к определенному сайту, еще совсем недавно нормально работавшему. Safari уведомляет о том, открыть страницу не удается из-за большого количества переадресаций, что в решении проблемы мало чем помогает. О том, из-за чего данная проблема проявляется и как от нее избавиться рассказали в этой инструкции.

Проблема, связанная с невозможностью Safari отобразить страницу из-за большого количества переадресаций, возникает из-за ошибок на конкретном веб-сайте. В большинстве случаев, исправить ее помогает удаление кэша и связанных с сайтом файлов cookie в настройках браузера. Сделать это можно в параметрах Safari на iPhone и iPad.

Safari не удается открыть страницу из-за большого количества переадресаций — что делать

Шаг 1. Перейдите в меню «Настройки» → Safari.

Шаг 2. В самом низу страницы выберите раздел «Дополнения».

Safari не удается открыть страницу из-за большого количества переадресаций — что делатьШаг 3. На открывшейся странице нажмите «Изменить» и удалите данные проблемного сайта.

Примечание: в Safari представлена возможность удаления данных всех сайтов сразу. Для этого необходимо перейти в меню «Настройки» → Safari и нажать «Очистить историю и данные сайтов».

Safari не удается открыть страницу из-за большого количества переадресаций — что делатьТаким простым образом в большинстве случаев решается проблема с открытием веб-сайтов в Safari на iPhone и iPad. Отметим, что помочь также может переход на проблемный сайт через любой сторонний браузер.

Смотрите также:

  • Как быстро загрузить музыку в iPhone через iTunes
  • iPhone выключается на холоде: причины и способы решения проблемы
  • Забыл пароль ограничений iPhone — что делать

✅ Подписывайтесь на нас в Telegram, ВКонтакте, и Яндекс.Дзен.

Safari не удается открыть страницу из-за большого количества переадресаций — что делать

В браузере Safari на iPhone и iPad нередко проявляется неприятная проблема, которая не позволяет пользователям получать доступ к определенному сайту, еще совсем недавно нормально работавшему. Safari уведомляет о том, открыть страницу не удается из-за большого количества переадресаций, что в решении проблемы мало чем помогает. О том, из-за чего данная проблема проявляется и как от нее избавиться рассказали в этой инструкции.

Проблема, связанная с невозможностью Safari отобразить страницу из-за большого количества переадресаций, возникает из-за ошибок на конкретном веб-сайте. В большинстве случаев, исправить ее помогает удаление кэша и связанных с сайтом файлов cookie в настройках браузера. Сделать это можно в параметрах Safari на iPhone и iPad.

Safari не удается открыть страницу из-за большого количества переадресаций — что делать

Шаг 1. Перейдите в меню «Настройки» → Safari.

Шаг 2. В самом низу страницы выберите раздел «Дополнения».

Safari не удается открыть страницу из-за большого количества переадресаций — что делатьШаг 3. На открывшейся странице нажмите «Изменить» и удалите данные проблемного сайта.

Примечание: в Safari представлена возможность удаления данных всех сайтов сразу. Для этого необходимо перейти в меню «Настройки» → Safari и нажать «Очистить историю и данные сайтов».

Safari не удается открыть страницу из-за большого количества переадресаций — что делатьТаким простым образом в большинстве случаев решается проблема с открытием веб-сайтов в Safari на iPhone и iPad. Отметим, что помочь также может переход на проблемный сайт через любой сторонний браузер.

Смотрите также:

  • Как быстро загрузить музыку в iPhone через iTunes
  • iPhone выключается на холоде: причины и способы решения проблемы
  • Забыл пароль ограничений iPhone — что делать

✅ Подписывайтесь на нас в Telegram, ВКонтакте, и Яндекс.Дзен.

We come across a lot of different errors here at Kinsta, and ERR_TOO_MANY_REDIRECTS (also known as a redirect loop) is one we see on a regular basis. Typically this occurs after a recent change on your website, a misconfiguration of redirects on your server, or wrong settings with third-party services. But don’t worry, this error is fairly easy to fix.

Check out the recommendations below on how to fix this error and get your site back up and running.

What is the ERR_TOO_MANY_REDIRECTS Error?

The ERR_TOO_MANY_REDIRECTS error is pretty much what it sounds like: something is causing too many redirects, sending your website into an infinite redirection loop.

Essentially the site is stuck (such as URL 1 points to URL 2 and URL 2 points back to URL 1, or the domain has redirected you too many times) and unlike some other errors, these rarely resolve themselves and will probably need you to take action to fix it.

You might have also come across the error “request exceeded the limit of 10 internal redirects due to probable configuration error“.

Error Code ERR_TOO_MANY_REDIRECTS
Error Type Browser error/code error
Error Variations This page isn’t working. domain.com redirected you too many times.
The page isn’t redirecting properly
This page isn’t working right now
Safari Can’t Open the Page
Error Causes Misconfigured WordPress settings/plugins
Issues with browser’s cache/cookies.
Issues with third-party services
Bad HTTPS settings
Bad server settings

There are a couple of different variations of this error depending upon the browser you’re running.

Google Chrome

In Google Chrome this error will show as ERR_TOO_MANY_REDIRECTS (as seen below) or This webpage has a redirect loop problem.

This page isn’t working. domain.com redirected you too many times.

ERR_TOO_MANY_REDIRECTS in Google Chrome

ERR_TOO_MANY_REDIRECTS in Google Chrome

(Check out how to fix Chrome’s ERR_CACHE_MISS error).

Mozilla Firefox

In Mozilla Firefox it will show as The page isn’t redirecting properly (as seen below).

An error occured during a connection to domain.com. This problem can sometimes be caused by disabling or refusing to accept cookies.

ERR_TOO_MANY_REDIRECTS in Firefox

ERR_TOO_MANY_REDIRECTS in Mozilla Firefox

Microsoft Edge

In Microsoft Edge, it will simply show as This page isn’t working right now (as seen below).

Domain.com redirected you too many times.

ERR_TOO_MANY_REDIRECTS in Microsoft Edge

ERR_TOO_MANY_REDIRECTS in Microsoft Edge

Safari

In Safari, it will show as Safari Can’t Open the Page (as seen below).

Too many redirects occurred trying to open “domain.com.” This might occur if you open a page that is redirected to open another page which is then redirected to open the original page.

ERR_TOO_MANY_REDIRECTS error in Safari

ERR_TOO_MANY_REDIRECTS error in Safari

Why Does ERR_TOO_MANY_REDIRECTS Error Occur?

This error happens when the browser can’t establish a connection between the initial page and the destination page in a redirect. The main causes can be:

  • Misconfigured WordPress settings
  • Misconfigured WordPress plugin.
  • Misconfigured server settings.
  • Incorrect HTTPS settings.
  • Issues with the browser’s cache/cookies.
  • Issues with third-party services (e.g. CDNs).
  • Improper website or domain migration.

So how to fix the ERR_TOO_MANY_REDIRECTS error?

Here are some recommendations and things to check to fix the error (sorted in order by most common reasons we see):

  • Delete cookies on that specific site
  • Clear site, server, proxy, and browser cache
  • Determine nature of redirect loop
  • Check your HTTPS settings
  • Check third-party services
  • Check your WordPress site settings
  • Temporarily disable WordPress plugins
  • Check redirects on your server

Delete Cookies on That Specific Site

Google and Mozilla both in fact recommend right below the error to “try clearing your cookies.” Cookies can sometimes contain faulty data in which could cause the ERR_TOO_MANY_REDIRECTS error. This is one recommendation you can try even if you’re encountering the error on a site you don’t own.

Due to the fact that cookies retain your “logged in” status on sites and other settings, we recommend simply deleting the cookie(s) on the site that is having the problem. This way you won’t impact any of your other sessions or websites that you frequently visit.

Follow the steps below to delete a cookie on a specific website in Google Chrome.

Step 1

In Google Chrome click on the three small dots in the upper right-hand corner. Then click on “Settings.”

Chrome settings

Chrome settings

Step 2

Scroll down and click on “Advanced.”

Chrome advanced settings

Chrome advanced settings

Step 3

Then click on “Content settings.”

Chrome content settings

Chrome content settings

Step 4

Click on “Cookies.”

Chrome cookies

Chrome cookies

Step 5

Then click on “See all cookies and site data.”

Chrome see all cookies

Chrome see all cookies

Step 6

Search for the site (domain) where you are encountering the ERR_TOO_MANY_REDIRECTS error. You can then delete the cookie(s) currently stored on your computer for that domain. Then try visiting the site again.

Delete cookie in Chrome

Delete cookie in Chrome

Clear Server, Proxy, and Browser Cache

Due to the fact that redirect loops are responses that can be cached, it’s always recommended to try clearing the cache on your WordPress site, the server, third-party proxy services, and even your browser if necessary.

Clear WordPress Site Cache

Depending upon the type of redirect loop, you might still be able to gain access to your WordPress admin dashboard. In this case, you can easily clear the cache within the settings of your caching plugin. Here are a couple of quick links on how to clear WordPress cache with popular plugins:

  • Clear Cache with Cache Enabler
  • Clear Cache with W3 Total Cache
  • Clear Cache with Super Cache

If you’re a Kinsta client, you can easily clear your cache from the WordPress admin toolbar.

Clear Kinsta cache from WordPress admin

Clear Kinsta cache from WordPress admin

Clear Server Cache

If you can’t access WordPress admin, many WordPress hosts have their own control panel tools for clearing the cache on your WordPress site.

If you’re a Kinsta client, you can manually clear WordPress cache from within the MyKinsta dashboard. Simply click on your site, click into tools, and click on the “Clear Cache” button. Then check your site to see if the redirect loop still exists.

Clear WordPress cache

Clear WordPress cache

Clear Proxy Cache

If you’re using a third-party reverse-proxy service such as Cloudflare or Sucuri, it can also be beneficial to clear the cache on their side.

Cloudflare

To purge Cloudflare cache, login to their dashboard, click into “Caching” and click on “Purge Everything.”

Purge cache

Sucuri

To purge Sucuri cache, login to their dashboard, go to “Performance” and click on “Clear Cache.”

Clear Sucuri cache

Clear Sucuri cache

Clear Browser Cache

If you want to check and see if it might be your browser cache, without clearing your cache, you can always open up your browser in incognito mode. Or test another browser and see if you still see the ERR_TOO_MANY_REDIRECTS error.

Open Chrome in Incognito mode

Open Chrome in Incognito mode

If you determine it is being caused by your browser cache, you can then clear it. Below are instructions on how to do it in various browsers:

  • How to Force Refresh a Single Page for All Browsers
  • How to Clear Browser Cache for Google Chrome
  • How to Clear Browser Cache for Mozilla Firefox
  • How to Clear Browser Cache for Safari
  • How to Clear Browser Cache for Internet Explorer
  • How to Clear Browser Cache for Microsoft Edge
  • How to Clear Browser Cache for Opera

Determine Nature of Redirect Loop

If clearing the cache didn’t work, then you’ll want to see if you can determine the nature of the redirect loop. Our free online Redirect Checker tool can help provide some further analysis into what might be going on. This could also be done via cURL.

For example, on the site below, it has a 301 redirect loop back to itself, which is causing a large chain of faulty redirects. You can follow all the redirects and determine whether or not it’s looping back to itself, or perhaps is an HTTP to HTTPS loop in which we’ll discuss how to solve that further below.

Too many redirects

Too many redirects

The Redirect Path Chrome extension can also be very useful and provides insights into all of the redirects happening on your site (specific URL or page.

Redirect Path extension

Redirect Path extension

Check Your HTTPS Settings

Another thing to check is your HTTPS settings. A lot of times we’ve seen ERR_TOO_MANY_REDIRECTS occur when someone has just migrated their WordPress site to HTTPS and either didn’t finish or set up something incorrectly.

1. Don’t Force HTTPS Without an SSL Certificate

This is by far the most common reason we see on a regular basis. If you force your WordPress site to load over HTTPS without first installing an SSL certificate, you’ll instantly throw your site into a redirection loop. To fix this, simply install an SSL certificate on your WordPress site.

It’s also recommended to run an SSL check. SSL/TLS certificates require not only your main certificate but also what they call intermediate certificates (chain) to also be installed. These need to be set up properly.

We recommend using the free SSL check tool from Qualys SSL Labs. It is very reliable and we use it for all Kinsta clients when verifying certificates. Simply head over to their SSL check tool, input your domain into the Hostname field and click on “Submit.” You can also select the option to hide public results if you prefer. It could take a minute or two to scan your site’s SSL/TLS configuration on your web server.

SSL check

SSL test

2. Don’t Use an SSL Plugin, Update your Hard-coded Links

There are some free SSL WordPress plugins, such as the Really Simple SSL plugin that will help you automatically redirect to HTTPS. However, we don’t recommend this method as a permanent solution because third-party plugins can always introduce another layer of problems and compatibility issues. It’s a good temporary solution, but you should really update your hard-coded HTTP links.

We have a great tutorial with 4 easy ways to do a search and replace in WordPress. If you’re a Kinsta client, you can always reach out to our support team to do this for you as well.

3. Check HTTP to HTTPS Redirects on Server

It could very well be that perhaps the HTTPS redirect rules on your server were misconfigured.

Redirect HTTP to HTTPS in Nginx

If your web server is running Nginx, you can easily redirect all of your HTTP traffic to HTTPS by adding the following code to your Nginx config file. This is the recommended method for redirecting WordPress running on Nginx.

server { listen 80; server_name domain.com www.domain.com; return 301 https://domain.com$request_uri; }

We use Nginx for everyone here at Kinsta. The great news is that you don’t have to worry about this. If you need to add a redirect simply open up a quick support ticket and let us know which domain you need to be redirected. We then add it to the Nginx config for you.

Check Out Our Video Guide to Redirects

Redirect HTTP to HTTPS in Apache

If your web server is running Apache, you can easily redirect all of your HTTP traffic to HTTPS by adding the following code to your .htaccess file. This is the recommended method for redirecting WordPress running on Apache.

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

4. Check For Too Many HTTPS Redirects

Perhaps you simply have too many HTTPS redirects. You can easily check your site to see how many redirects it’s using with a tool like Redirect Checker. Here is an example below of redirects that are not set up correctly which are easily spottable using an online tool. You can see that there are duplicate HTTPS redirects happening on both the www and non-www versions.

redirects not setup correctly

Redirects

Check Third-Party Services

ERR_TOO_MANY_REDIRECTS is also often commonly caused by reverse-proxy services such as Cloudflare. This usually happens when their Flexible SSL option is enabled and you already have an SSL certificate installed with your WordPress host. Why? Because, when flexible is selected, all requests to your hosting server are sent over HTTP. Your host server most likely already has a redirect in place from HTTP to HTTPS, and therefore a redirect loop occurs.

To fix this you need to change the Cloudflare Crypto settings from Flexible to either Full or Full (strict). If you’re a Kinsta client, make sure to also check out our steps on how to install an SSL certificate while using Cloudflare.

Cloudflare full

Set Cloudflare crypto level to full

You can use their Always Use HTTPS page rule to redirect all users to HTTPS without creating a loop. Another thing to watch out for with Cloudflare is their forwarding URL redirection rules. Be careful not to create a redirect where the domain points to itself as a destination. This can cause an infinite redirect error, and the affected URLs will not be able to resolve.

If you’re using StackPath, they have an option called “Origin Pull Protocol” that needs to be set to HTTPS only.

Using Cloudflare DNS Only

If you only want to use Cloudflare’s DNS, and not their proxy/WAF service, then you should make sure your DNS records are set to “DNS Only.” The clouds will appear as “grey” instead of “orange.” You configure this under the “DNS” tab in the Cloudflare control panel.

Cloudflare DNS only

Cloudflare DNS only

Check Your WordPress Site Settings

Another thing to check is your WordPress site settings. There are two different fields you’ll want to ensure are set correctly, and not pointing at a wrong domain or are mismatched. Another common mistake is that you’re not using the correct prefix to match the rest of your site, www or non-www. Sometimes people migrate hosts, or change domains and these can get changed without you realizing it.

  • WordPress Address (URL): The address to reach your blog.
  • Site Address (URL): The address of your WordPress core files.

Both should match unless you are giving WordPress its own directory.

WordPress address

WordPress address

Most likely though you aren’t able to access your WordPress dashboard. So what you can do is override the settings above by inputting the values in your wp-config.php file.

The wp-config.php file is typically located at the root of your WordPress site and can be accessed via FTP, SSH, or WP-CLI. To hard-code WP_HOME and WP_SITEURL, simply input the following code towards the top of the file, changing the values to reflect your domain.

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

Below is an example of what your wp-config.php file might look like afterward.

change wordpress url wp-config.php

Change WordPress URL in wp-config.php file

Or if you prefer, here are two additional ways you could change your WordPress URLs without access to your admin dashboard:

  • Change WordPress URL Directly in Database
  • Change WordPress URL With WP-CLI

Once you manually set it, you can browse to your site to verify whether or not it fixes the redirect loop.

Multisite

If you’re changing domains on a multisite, make sure to also check the wp_blogs table. We’ve seen people do a search and replace wrong and cause an infinite redirect loop. This is because the network site doesn’t match the subsites.

wp_#_options: Each subsite will have sets of tables that correspond to the blog_id in the wp_blogs table. Go to the wp_#_options table, where # corresponds to the blog_id, and update the “SITEURL” and “HOME” settings in that table.

Temporarily Disable WordPress Plugins

When it comes to WordPress, temporarily disabling all your WordPress plugins can be a quick way to spot problems. For example, plugins such as Redirection or Yoast SEO premium let you implement redirects. Sometimes settings or updates to these plugins can conflict with redirects that might already be set on your server, causing a redirect loop.

Remember, you won’t lose any data if you simply disable a plugin. Most likely you can’t access the WordPress admin, so you’ll need login via SFTP to your server and rename your plugins folder to something like plugins_old. Then check your site again.

SFTP rename plugins folder

SFTP rename plugins folder

If it works, then you will need to test each plugin one by one. Rename your plugin folder back to “plugins” and then rename each plugin folder inside of if it, one by one, until you find it. You could also try to replicate this on a staging site first.

Rename plugin folder

Rename plugin folder

Check Redirects on Your Server

Besides HTTP to HTTPS redirects on your server, it can be good to check and make sure there aren’t any additional redirects setup wrong. For example, one bad 301 redirect back to itself could take down your site. Usually, these are found in your server’s config files.

Apache .htaccess file

Kinsta only uses Nginx, but if you’re using a WordPress host that is running Apache, it could very well be that your .htaccess file has a wrong rule in it. Follow the steps below to recreate a new one from scratch.

First, login to your site via FTP or SSH, and rename your .htaccess file to .htaccess_old. This ensures you have a backup.

Rename .htaccess file

Rename .htaccess file

Normally to recreate this file you can simply re-save your permalinks in WordPress. However, if you’re in the middle of an ERR_TOO_MANY_REDIRECTS error you most likely can’t access your WordPress admin, so this isn’t an option. Therefore you can create a new .htaccess file and input the following contents. Then upload it to your server. The following uses the default settings.

# 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

See the WordPress Codex for more examples, such as a default .htaccess file for multisite.

We’ve taken our knowledge of effective website management at scale, and turned it into an ebook and video course. Click here to download the The 2020 Guide to Managing 40+ WordPress Sites!

Nginx Config

If your host uses Nginx, this file can be a little trickier as the config file can vary a bit depending on the hosting provider. We recommend reaching out to your host and have them check your config file for anything that might be causing a redirect loop or too many redirects.

If you’re a Kinsta client, you’ll first want to check to ensure you didn’t set up a redirect wrong in our redirect tool. Below is a simple example of a redirect from https://domain.com/ back to itself, that would cause a redirect loop.

Bad 301 redirect

Bad 301 redirect

This also commonly happens when the location URL is included in both “Redirect From” and “Redirection To.”

For example, the following would cause a redirect loop:

Redirect From: ^/blog/about Redirect To: https://domain.com/blog/about-me

Why? Because once the process reached ^/blog/about, the remaining part -me wouldn’t matter, and it would cause an infinite loop. You have to specify the end of the string and the starter point. Here is what you would do to fix it:

Redirect From: ^/blog/about$ Redirect To: https://domain.com/blog/about-me

The $ character will tell Nginx to stop and match the request only if the string is there exactly, but nothing after it.

And of course, you can always open up a support ticket and we’ll check this for you.

Misconfigured Reverse Proxies

Another common reason for the ERR_TOO_MANY_REDIRECTS error is if you are using a reverse proxy. Reverse proxies can be quite complicated and it’s very easy to send your WordPress site into a redirect loop if misconfigured. Again, if you’re a Kinsta client, our support team can help with this.

Website stuck in an infinite redirection loop? 🛣 Check out these recommendations on how to get back up and running fast.Click to Tweet

Summary

Redirect loops can sometimes be tricky to track down. But hopefully, some of the troubleshooting steps above help you to resolve your ERR_TOO_MANY_REDIRECTS error. If we missed anything, feel free to let us know below in the comments.


Get all your applications, databases and WordPress sites online and under one roof. Our feature-packed, high-performance cloud platform includes:

  • Easy setup and management in the MyKinsta dashboard
  • 24/7 expert support
  • The best Google Cloud Platform hardware and network, powered by Kubernetes for maximum scalability
  • An enterprise-level Cloudflare integration for speed and security
  • Global audience reach with up to 35 data centers and 275+ PoPs worldwide

Test it yourself with $20 off your first month of Application Hosting or Database Hosting. Explore our plans or talk to sales to find your best fit.

We come across a lot of different errors here at Kinsta, and ERR_TOO_MANY_REDIRECTS (also known as a redirect loop) is one we see on a regular basis. Typically this occurs after a recent change on your website, a misconfiguration of redirects on your server, or wrong settings with third-party services. But don’t worry, this error is fairly easy to fix.

Check out the recommendations below on how to fix this error and get your site back up and running.

What is the ERR_TOO_MANY_REDIRECTS Error?

The ERR_TOO_MANY_REDIRECTS error is pretty much what it sounds like: something is causing too many redirects, sending your website into an infinite redirection loop.

Essentially the site is stuck (such as URL 1 points to URL 2 and URL 2 points back to URL 1, or the domain has redirected you too many times) and unlike some other errors, these rarely resolve themselves and will probably need you to take action to fix it.

You might have also come across the error “request exceeded the limit of 10 internal redirects due to probable configuration error“.

Error Code ERR_TOO_MANY_REDIRECTS
Error Type Browser error/code error
Error Variations This page isn’t working. domain.com redirected you too many times.
The page isn’t redirecting properly
This page isn’t working right now
Safari Can’t Open the Page
Error Causes Misconfigured WordPress settings/plugins
Issues with browser’s cache/cookies.
Issues with third-party services
Bad HTTPS settings
Bad server settings

There are a couple of different variations of this error depending upon the browser you’re running.

Google Chrome

In Google Chrome this error will show as ERR_TOO_MANY_REDIRECTS (as seen below) or This webpage has a redirect loop problem.

This page isn’t working. domain.com redirected you too many times.

ERR_TOO_MANY_REDIRECTS in Google Chrome

ERR_TOO_MANY_REDIRECTS in Google Chrome

(Check out how to fix Chrome’s ERR_CACHE_MISS error).

Mozilla Firefox

In Mozilla Firefox it will show as The page isn’t redirecting properly (as seen below).

An error occured during a connection to domain.com. This problem can sometimes be caused by disabling or refusing to accept cookies.

ERR_TOO_MANY_REDIRECTS in Firefox

ERR_TOO_MANY_REDIRECTS in Mozilla Firefox

Microsoft Edge

In Microsoft Edge, it will simply show as This page isn’t working right now (as seen below).

Domain.com redirected you too many times.

ERR_TOO_MANY_REDIRECTS in Microsoft Edge

ERR_TOO_MANY_REDIRECTS in Microsoft Edge

Safari

In Safari, it will show as Safari Can’t Open the Page (as seen below).

Too many redirects occurred trying to open “domain.com.” This might occur if you open a page that is redirected to open another page which is then redirected to open the original page.

ERR_TOO_MANY_REDIRECTS error in Safari

ERR_TOO_MANY_REDIRECTS error in Safari

Why Does ERR_TOO_MANY_REDIRECTS Error Occur?

This error happens when the browser can’t establish a connection between the initial page and the destination page in a redirect. The main causes can be:

  • Misconfigured WordPress settings
  • Misconfigured WordPress plugin.
  • Misconfigured server settings.
  • Incorrect HTTPS settings.
  • Issues with the browser’s cache/cookies.
  • Issues with third-party services (e.g. CDNs).
  • Improper website or domain migration.

So how to fix the ERR_TOO_MANY_REDIRECTS error?

Here are some recommendations and things to check to fix the error (sorted in order by most common reasons we see):

  • Delete cookies on that specific site
  • Clear site, server, proxy, and browser cache
  • Determine nature of redirect loop
  • Check your HTTPS settings
  • Check third-party services
  • Check your WordPress site settings
  • Temporarily disable WordPress plugins
  • Check redirects on your server

Delete Cookies on That Specific Site

Google and Mozilla both in fact recommend right below the error to “try clearing your cookies.” Cookies can sometimes contain faulty data in which could cause the ERR_TOO_MANY_REDIRECTS error. This is one recommendation you can try even if you’re encountering the error on a site you don’t own.

Due to the fact that cookies retain your “logged in” status on sites and other settings, we recommend simply deleting the cookie(s) on the site that is having the problem. This way you won’t impact any of your other sessions or websites that you frequently visit.

Follow the steps below to delete a cookie on a specific website in Google Chrome.

Step 1

In Google Chrome click on the three small dots in the upper right-hand corner. Then click on “Settings.”

Chrome settings

Chrome settings

Step 2

Scroll down and click on “Advanced.”

Chrome advanced settings

Chrome advanced settings

Step 3

Then click on “Content settings.”

Chrome content settings

Chrome content settings

Step 4

Click on “Cookies.”

Chrome cookies

Chrome cookies

Step 5

Then click on “See all cookies and site data.”

Chrome see all cookies

Chrome see all cookies

Step 6

Search for the site (domain) where you are encountering the ERR_TOO_MANY_REDIRECTS error. You can then delete the cookie(s) currently stored on your computer for that domain. Then try visiting the site again.

Delete cookie in Chrome

Delete cookie in Chrome

Clear Server, Proxy, and Browser Cache

Due to the fact that redirect loops are responses that can be cached, it’s always recommended to try clearing the cache on your WordPress site, the server, third-party proxy services, and even your browser if necessary.

Clear WordPress Site Cache

Depending upon the type of redirect loop, you might still be able to gain access to your WordPress admin dashboard. In this case, you can easily clear the cache within the settings of your caching plugin. Here are a couple of quick links on how to clear WordPress cache with popular plugins:

  • Clear Cache with Cache Enabler
  • Clear Cache with W3 Total Cache
  • Clear Cache with Super Cache

If you’re a Kinsta client, you can easily clear your cache from the WordPress admin toolbar.

Clear Kinsta cache from WordPress admin

Clear Kinsta cache from WordPress admin

Clear Server Cache

If you can’t access WordPress admin, many WordPress hosts have their own control panel tools for clearing the cache on your WordPress site.

If you’re a Kinsta client, you can manually clear WordPress cache from within the MyKinsta dashboard. Simply click on your site, click into tools, and click on the “Clear Cache” button. Then check your site to see if the redirect loop still exists.

Clear WordPress cache

Clear WordPress cache

Clear Proxy Cache

If you’re using a third-party reverse-proxy service such as Cloudflare or Sucuri, it can also be beneficial to clear the cache on their side.

Cloudflare

To purge Cloudflare cache, login to their dashboard, click into “Caching” and click on “Purge Everything.”

Purge cache

Sucuri

To purge Sucuri cache, login to their dashboard, go to “Performance” and click on “Clear Cache.”

Clear Sucuri cache

Clear Sucuri cache

Clear Browser Cache

If you want to check and see if it might be your browser cache, without clearing your cache, you can always open up your browser in incognito mode. Or test another browser and see if you still see the ERR_TOO_MANY_REDIRECTS error.

Open Chrome in Incognito mode

Open Chrome in Incognito mode

If you determine it is being caused by your browser cache, you can then clear it. Below are instructions on how to do it in various browsers:

  • How to Force Refresh a Single Page for All Browsers
  • How to Clear Browser Cache for Google Chrome
  • How to Clear Browser Cache for Mozilla Firefox
  • How to Clear Browser Cache for Safari
  • How to Clear Browser Cache for Internet Explorer
  • How to Clear Browser Cache for Microsoft Edge
  • How to Clear Browser Cache for Opera

Determine Nature of Redirect Loop

If clearing the cache didn’t work, then you’ll want to see if you can determine the nature of the redirect loop. Our free online Redirect Checker tool can help provide some further analysis into what might be going on. This could also be done via cURL.

For example, on the site below, it has a 301 redirect loop back to itself, which is causing a large chain of faulty redirects. You can follow all the redirects and determine whether or not it’s looping back to itself, or perhaps is an HTTP to HTTPS loop in which we’ll discuss how to solve that further below.

Too many redirects

Too many redirects

The Redirect Path Chrome extension can also be very useful and provides insights into all of the redirects happening on your site (specific URL or page.

Redirect Path extension

Redirect Path extension

Check Your HTTPS Settings

Another thing to check is your HTTPS settings. A lot of times we’ve seen ERR_TOO_MANY_REDIRECTS occur when someone has just migrated their WordPress site to HTTPS and either didn’t finish or set up something incorrectly.

1. Don’t Force HTTPS Without an SSL Certificate

This is by far the most common reason we see on a regular basis. If you force your WordPress site to load over HTTPS without first installing an SSL certificate, you’ll instantly throw your site into a redirection loop. To fix this, simply install an SSL certificate on your WordPress site.

It’s also recommended to run an SSL check. SSL/TLS certificates require not only your main certificate but also what they call intermediate certificates (chain) to also be installed. These need to be set up properly.

We recommend using the free SSL check tool from Qualys SSL Labs. It is very reliable and we use it for all Kinsta clients when verifying certificates. Simply head over to their SSL check tool, input your domain into the Hostname field and click on “Submit.” You can also select the option to hide public results if you prefer. It could take a minute or two to scan your site’s SSL/TLS configuration on your web server.

SSL check

SSL test

2. Don’t Use an SSL Plugin, Update your Hard-coded Links

There are some free SSL WordPress plugins, such as the Really Simple SSL plugin that will help you automatically redirect to HTTPS. However, we don’t recommend this method as a permanent solution because third-party plugins can always introduce another layer of problems and compatibility issues. It’s a good temporary solution, but you should really update your hard-coded HTTP links.

We have a great tutorial with 4 easy ways to do a search and replace in WordPress. If you’re a Kinsta client, you can always reach out to our support team to do this for you as well.

3. Check HTTP to HTTPS Redirects on Server

It could very well be that perhaps the HTTPS redirect rules on your server were misconfigured.

Redirect HTTP to HTTPS in Nginx

If your web server is running Nginx, you can easily redirect all of your HTTP traffic to HTTPS by adding the following code to your Nginx config file. This is the recommended method for redirecting WordPress running on Nginx.

server { listen 80; server_name domain.com www.domain.com; return 301 https://domain.com$request_uri; }

We use Nginx for everyone here at Kinsta. The great news is that you don’t have to worry about this. If you need to add a redirect simply open up a quick support ticket and let us know which domain you need to be redirected. We then add it to the Nginx config for you.

Check Out Our Video Guide to Redirects

Redirect HTTP to HTTPS in Apache

If your web server is running Apache, you can easily redirect all of your HTTP traffic to HTTPS by adding the following code to your .htaccess file. This is the recommended method for redirecting WordPress running on Apache.

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

4. Check For Too Many HTTPS Redirects

Perhaps you simply have too many HTTPS redirects. You can easily check your site to see how many redirects it’s using with a tool like Redirect Checker. Here is an example below of redirects that are not set up correctly which are easily spottable using an online tool. You can see that there are duplicate HTTPS redirects happening on both the www and non-www versions.

redirects not setup correctly

Redirects

Check Third-Party Services

ERR_TOO_MANY_REDIRECTS is also often commonly caused by reverse-proxy services such as Cloudflare. This usually happens when their Flexible SSL option is enabled and you already have an SSL certificate installed with your WordPress host. Why? Because, when flexible is selected, all requests to your hosting server are sent over HTTP. Your host server most likely already has a redirect in place from HTTP to HTTPS, and therefore a redirect loop occurs.

To fix this you need to change the Cloudflare Crypto settings from Flexible to either Full or Full (strict). If you’re a Kinsta client, make sure to also check out our steps on how to install an SSL certificate while using Cloudflare.

Cloudflare full

Set Cloudflare crypto level to full

You can use their Always Use HTTPS page rule to redirect all users to HTTPS without creating a loop. Another thing to watch out for with Cloudflare is their forwarding URL redirection rules. Be careful not to create a redirect where the domain points to itself as a destination. This can cause an infinite redirect error, and the affected URLs will not be able to resolve.

If you’re using StackPath, they have an option called “Origin Pull Protocol” that needs to be set to HTTPS only.

Using Cloudflare DNS Only

If you only want to use Cloudflare’s DNS, and not their proxy/WAF service, then you should make sure your DNS records are set to “DNS Only.” The clouds will appear as “grey” instead of “orange.” You configure this under the “DNS” tab in the Cloudflare control panel.

Cloudflare DNS only

Cloudflare DNS only

Check Your WordPress Site Settings

Another thing to check is your WordPress site settings. There are two different fields you’ll want to ensure are set correctly, and not pointing at a wrong domain or are mismatched. Another common mistake is that you’re not using the correct prefix to match the rest of your site, www or non-www. Sometimes people migrate hosts, or change domains and these can get changed without you realizing it.

  • WordPress Address (URL): The address to reach your blog.
  • Site Address (URL): The address of your WordPress core files.

Both should match unless you are giving WordPress its own directory.

WordPress address

WordPress address

Most likely though you aren’t able to access your WordPress dashboard. So what you can do is override the settings above by inputting the values in your wp-config.php file.

The wp-config.php file is typically located at the root of your WordPress site and can be accessed via FTP, SSH, or WP-CLI. To hard-code WP_HOME and WP_SITEURL, simply input the following code towards the top of the file, changing the values to reflect your domain.

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

Below is an example of what your wp-config.php file might look like afterward.

change wordpress url wp-config.php

Change WordPress URL in wp-config.php file

Or if you prefer, here are two additional ways you could change your WordPress URLs without access to your admin dashboard:

  • Change WordPress URL Directly in Database
  • Change WordPress URL With WP-CLI

Once you manually set it, you can browse to your site to verify whether or not it fixes the redirect loop.

Multisite

If you’re changing domains on a multisite, make sure to also check the wp_blogs table. We’ve seen people do a search and replace wrong and cause an infinite redirect loop. This is because the network site doesn’t match the subsites.

wp_#_options: Each subsite will have sets of tables that correspond to the blog_id in the wp_blogs table. Go to the wp_#_options table, where # corresponds to the blog_id, and update the “SITEURL” and “HOME” settings in that table.

Temporarily Disable WordPress Plugins

When it comes to WordPress, temporarily disabling all your WordPress plugins can be a quick way to spot problems. For example, plugins such as Redirection or Yoast SEO premium let you implement redirects. Sometimes settings or updates to these plugins can conflict with redirects that might already be set on your server, causing a redirect loop.

Remember, you won’t lose any data if you simply disable a plugin. Most likely you can’t access the WordPress admin, so you’ll need login via SFTP to your server and rename your plugins folder to something like plugins_old. Then check your site again.

SFTP rename plugins folder

SFTP rename plugins folder

If it works, then you will need to test each plugin one by one. Rename your plugin folder back to “plugins” and then rename each plugin folder inside of if it, one by one, until you find it. You could also try to replicate this on a staging site first.

Rename plugin folder

Rename plugin folder

Check Redirects on Your Server

Besides HTTP to HTTPS redirects on your server, it can be good to check and make sure there aren’t any additional redirects setup wrong. For example, one bad 301 redirect back to itself could take down your site. Usually, these are found in your server’s config files.

Apache .htaccess file

Kinsta only uses Nginx, but if you’re using a WordPress host that is running Apache, it could very well be that your .htaccess file has a wrong rule in it. Follow the steps below to recreate a new one from scratch.

First, login to your site via FTP or SSH, and rename your .htaccess file to .htaccess_old. This ensures you have a backup.

Rename .htaccess file

Rename .htaccess file

Normally to recreate this file you can simply re-save your permalinks in WordPress. However, if you’re in the middle of an ERR_TOO_MANY_REDIRECTS error you most likely can’t access your WordPress admin, so this isn’t an option. Therefore you can create a new .htaccess file and input the following contents. Then upload it to your server. The following uses the default settings.

# 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

See the WordPress Codex for more examples, such as a default .htaccess file for multisite.

We’ve taken our knowledge of effective website management at scale, and turned it into an ebook and video course. Click here to download the The 2020 Guide to Managing 40+ WordPress Sites!

Nginx Config

If your host uses Nginx, this file can be a little trickier as the config file can vary a bit depending on the hosting provider. We recommend reaching out to your host and have them check your config file for anything that might be causing a redirect loop or too many redirects.

If you’re a Kinsta client, you’ll first want to check to ensure you didn’t set up a redirect wrong in our redirect tool. Below is a simple example of a redirect from https://domain.com/ back to itself, that would cause a redirect loop.

Bad 301 redirect

Bad 301 redirect

This also commonly happens when the location URL is included in both “Redirect From” and “Redirection To.”

For example, the following would cause a redirect loop:

Redirect From: ^/blog/about Redirect To: https://domain.com/blog/about-me

Why? Because once the process reached ^/blog/about, the remaining part -me wouldn’t matter, and it would cause an infinite loop. You have to specify the end of the string and the starter point. Here is what you would do to fix it:

Redirect From: ^/blog/about$ Redirect To: https://domain.com/blog/about-me

The $ character will tell Nginx to stop and match the request only if the string is there exactly, but nothing after it.

And of course, you can always open up a support ticket and we’ll check this for you.

Misconfigured Reverse Proxies

Another common reason for the ERR_TOO_MANY_REDIRECTS error is if you are using a reverse proxy. Reverse proxies can be quite complicated and it’s very easy to send your WordPress site into a redirect loop if misconfigured. Again, if you’re a Kinsta client, our support team can help with this.

Website stuck in an infinite redirection loop? 🛣 Check out these recommendations on how to get back up and running fast.Click to Tweet

Summary

Redirect loops can sometimes be tricky to track down. But hopefully, some of the troubleshooting steps above help you to resolve your ERR_TOO_MANY_REDIRECTS error. If we missed anything, feel free to let us know below in the comments.


Get all your applications, databases and WordPress sites online and under one roof. Our feature-packed, high-performance cloud platform includes:

  • Easy setup and management in the MyKinsta dashboard
  • 24/7 expert support
  • The best Google Cloud Platform hardware and network, powered by Kubernetes for maximum scalability
  • An enterprise-level Cloudflare integration for speed and security
  • Global audience reach with up to 35 data centers and 275+ PoPs worldwide

Test it yourself with $20 off your first month of Application Hosting or Database Hosting. Explore our plans or talk to sales to find your best fit.

[Решено] | ОШИБКА СЛИШКОМ МНОГО ПЕРЕАДРЕСАЦИЙ Быстро и легко

На чтение 4 мин. Просмотров 4.6k. Опубликовано 02.06.2021

20

Если вы видите « ERR_TOO_MANY_REDIRECTS » в своем веб-браузере, вы не одиноки. Об этом сообщили многие пользователи Windows. Эта ошибка возникает с сообщением « Эта веб-страница имеет цикл переадресации » и блокирует загрузку веб-сайта.

Почему возникла эта ошибка ?

Эта проблема обычно возникает, когда вы перенаправляетесь с исходного URL-адреса на новый, но, к сожалению, попадаете в бесконечный цикл перенаправления. Браузер обнаруживает эту ситуацию, прерывает цикл и отображает сообщение об ошибке. Причина, по которой вы застряли в этом цикле, может быть проблемой сервера или конечного пользователя.

Как исправить эту ошибку?

Вот четыре способа исправить эту ошибку цикла перенаправления ERR_TOO_MANY_REDIRECTS:

1) Протестируйте в других браузерах

2) Очистите данные вашего браузера

3) Проверьте расширения вашего браузера

4) Исправьте дату и время в системе.

Содержание

  1. 1) Протестируйте в других браузерах
  2. 2) Очистите данные вашего браузера
  3. 3) Проверьте расширения вашего браузера
  4. 4) Исправьте дату и время в вашей системе
  5. Вы также можете прочитать…

1) Протестируйте в других браузерах

Ошибка ERR_TOO_MANY_REDIRECTS может возникнуть из-за используемого вами веб-браузера. Вы можете попробовать посетить тот же URL в других браузерах . Если ошибка не устранена, проблема может исходить от сервера. Возможно, вам потребуется войти на сайт в другое время. Если ошибка не появляется в новом браузере, попробуйте следующие методы, чтобы исправить проблемы в исходном браузере.

2) Очистите данные вашего браузера

Данные браузера например, история просмотров, кеш, файлы cookie и т. д. могут содержать неисправные файлы, которые вызывают ошибку ERR_TOO_MANY_REDIRECTS. Очистка этих данных – эффективный способ исправить ошибку. Чтобы очистить данные просмотра :

В Google Chrome :

а) Введите « chrome://settings » в адресную строку и нажмите Enter , а затем нажмите Показать дополнительные настройки в внизу страницы настроек.

б) Нажмите Кнопка Очистить данные просмотра .

c) Нажмите Очистить данные просмотра .

И на Mozilla Firefox :

a) Нажмите кнопку Меню в Firefox, а затем выберите Параметры .

б) Выберите Конфиденциальность , а затем очистите вашу недавнюю историю .

c) Выберите Everything для Time диапазон, который нужно очистить, и затем нажмите Очистить сейчас .

После того, как данные браузера очищены, вы можете попробовать войти на веб-сайт и посмотреть, исчезла ли ошибка.

3) Проверьте расширения вашего браузера

Ошибка ERR_TOO_MANY_REDIRECTS может быть вызвана неправильное расширение браузера. Вы должны открыть диспетчер расширений в своем браузере, чтобы проверить расширения, которые вы установили в своем браузере.

Вот примеры проверки расширений в Chrome и Firefox.

a) Для Chrome введите « chrome ://extensions »в адресной строке и нажмите Enter . После этого вы увидите все перечисленные расширения. ниже, и вы можете попробовать включить или отключить любой из них.

b) Для Firefox введите « about: addons » в адресную строку, нажмите Введите , , а затем выберите Расширения . Вы увидите, что все расширения для Firefox перечислены здесь.

Вы можете отключить все расширения , чтобы проверить, решит ли это проблему. Если это так, вы можете активировать по одному расширению за раз , чтобы определить то, которое вызывает проблему.

4) Исправьте дату и время в вашей системе

Обычно ошибка ERR_TOO_MANY_REDIRECTS возникает из-за неправильных или устаревших настроек даты и времени в вашей системе. Чтобы исправить системную дату и время.

a) Нажмите клавиши Win + R на клавиатуре, чтобы вызвать окно «Выполнить». Введите « control » и нажмите Enter .

На панели управления выберите Дата и время .

c) Выберите вкладку Интернет-время и затем нажмите Изменить настройки .

г) В настройках времени в Интернете отметьте Синхронизировать с сервером времени в Интернете и выберите сервер времени . Затем нажмите Обновить сейчас и нажмите OK .

Дата и время в вашей системе теперь обновлены.

Вы также можете прочитать…

Как для подключения вашего компьютера к VPN.

While many web browsers are available for the macOS and iOS, many users are content with Apple’s default browser.

Being able to checkmark all the essential prerequisites and the fact that it is deeply integrated into the Apple ecosystem are two primary reasons why users generally don’t feel a need to switch.

However, despite its perks, it also has its fair share of issues. Among them, the redirect issue seems to be bugging quite a few users as of late.

When they click on a link, it sends them to another page of that site, which will send them back to the first link/page.

As a result, you will be stuck in an infinite redirection loop. In hindsight, there could be three plausible reasons for this error- Apple’s new Intelligent Tracking Prevention feature, corrupt website data, or how a website is designed.

Safari cannot open the page because too many redirect occurred

There are chances that Safari is infected by malware, which results in this undefined behavior. Hence, we should consider removing the malware from Safari if that’s the case.

Let’s try and understand how they could lead to the redirection issue and, more importantly, how to deal with them effectively.

And by the end of this guide, you will be able to fix Safari’s too many redirects issues or at least identify the root cause.

Disable Safari Intelligent Tracking Prevention

Recently Apple rolled out the Intelligent Tracking Prevention feature to the Safari browser.

Using Machine Learning, it checks how a user interacts with a particular site and then deals with the trackers, ads, and third-party cookies accordingly. You can check ITP in action under Safari Privacy Reports feature. However, the ITP seems to conflict with the sites using an authentication service.

They are preventing the site from establishing a successful connection for the authentication procedure and are stuck within their environment. This, in turn, gives out the redirection error. So the fix for the same is pretty simple- disable the ITP.

Note: Keeping the ITP disabled is not recommended. If you love the privacy and want to keep your data safe, then enable the Intelligent Tracking Prevention immediately after you troubleshoot the redirect loop issue

Here are the steps to disable Safari Intelligent Tracking Prevention (ITP) on Mac:

  1. Launch Apple Safari on a Mac computer.
  2. Click on the Safari menu from the menubar options.
  3. Choose the Preferences menu from the drop-down list.
    It will open the Safari Preferences window.
  4. Switch to the Privacy tab, and uncheck the Prevent cross-site tracking option.
    Disable Prevent Cross Site Tracking for Safari ITP

That’s it. The Mac Safari’s ITP will be disabled and cross-site tracking will be enabled again. Similarly, we can also disable the ITP for iPhone or iPad Safari browsers.

Here are the steps to disable Safari ITP on iPhone or iPad:

  1. Launch the Phone Settings on your iPhone/iPad.
  2. Scroll and select the Safari app.
    It will open the Safari Settings pages.
  3. Turn off the Prevent Cross-Site Tracking option on the Safari Settings page.
    Disable Prevent Cross Site Tracking in Safari iPhone

Once you have disabled the Tracking option for your Safari browser, retry visiting the concerned site. Then verify whether the too many redirects issue in Safari has been fixed.

Delete Website’s Data

All the redirects you perform from one site to another are stored inside the cache and cookie data. If this data gets outdated or corrupted, the concerned sites are bound to have issues.

Therefore, you should consider deleting that site’s data so that it can generate a fresh one from scratch.

Here are the steps to delete the website data from Mac Computer:

  1. Launch the Safari browser on your Mac.
  2. Click on the Safari menu from the menubar, and select Preferences from the menu.
    It will open the Safari Preferences window.
  3. Switch to the Privacy tab, and hit on Manage Website Data… button.
    Safari Mac Manage Website Data button under Privacy
  4. Head over to the Search field and type the name of the website URL address.
  5. Select the site from the search result, and hit the Remove button.
    Search Select and Remove Cookies and Website Data from Safari Mac

Safari will now delete the cache and cookies of that site. Now try accessing it and check whether Safari’s too many redirects issue has been fixed.

If you still face this issue, open the Manage Website Data window. Rather than deleting the data for a particular site, hit on Remove All to delete all site data you have visited on Safari.

Remove all cookies and storage data from Safari browser

While doing so will sign you out of all the sites, it might rectify the redirect issue as well, which will definitely be worth the effort.

You can also perform similar website data clean-up on Safari for iPhone or iPad devices.

Contact Website Admin

Sometimes, a backend issue might be with a site constantly sending you into a redirect loop. Or the website might have intentionally done so to lower its bounce rate and improve the search algorithm.

There’s not much you could do in such cases, whether it is deliberate or otherwise, apart from contacting the site’s owner.

Find that site’s Contact Us/About Us page and get in touch with them regarding this issue. They should then chalk out the best route forward to fix the issue as soon as possible.

You can use the domain lookup service to find and contact the website owner if the website is inaccessible.

Bottom Line: Safari Redirect Error

We round off the guide on how to fix the issue of Safari too many redirects occurred.

Being unable to access the desired site and instead being caught in a redirection loop is probably the most infuriating user experience. Fortunately, you now know three different methods to get out of it.

In my case, deleting that concerned site’s data (cache and cookies) did manage to rectify the underlying issue.

Do let us know which method spelled out success for you in troubleshooting and fixing the Safari redirect loop error.

Lastly, here are the recommended web browsers for computer and mobile phone that you should give a try.

If you’ve any thoughts on How to Fix: Safari too many redirects occurred?, then feel free to drop in below comment box.

Disclosure: This page may contain affiliate links, which means we may receive compensation for your purchases using our links; of course at no extra cost to you (indeed, you may get special discounts).

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 the user experience or conversions on your site.

Site owner fixing too many redirects error

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.

Speed Up Your Website with HubSpot's Built-In CDN

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 chrome

Image Source

Too Many Redirects Safari

too many redirects safari

Image Source

Too Many Redirects Firefox

too many redirects firefox

Image Source

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

  1. Clear cookies on the redirecting website.
  2. Clear your browser cache.
  3. Ensure your SSL certificate is installed correctly.
  4. Evaluate your third-party services and plugins.
  5. Reset your htaccess file.
  6. Contact your hosting provider.

These steps apply to any website, no matter what website builder or content 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 out How to Fix the Redirect Loop Error in WordPress to 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 the Customize icon then click Settings.

Navigate to setting to clear cookies on Chrome

  • Click Privacy and security from the left toolbar.
  • Click Cookies and other site data.

Click Cookies and other site data on Chrome

  • Scroll down and click See all cookies and site data.

Click see all cookies and other data on Chrome

  • At the top right, search for the website’s name.
  • To the right of the site, click Remove.

Click remove redirecting loop website on Chrome

Safari

  • Click Safari > Preferences.

click Safari > Preferences to clear cookies

  • Click Privacy.
  • Click Manage Website Data.

Click manage website data to clear cookies on safari

  • Use the Search field to find the name of the website causing the redirect loop.
  • Select the site and click Remove.

Remove redirecting website on Safari

  • Click Done.

Firefox

  • Click Firefox > Preferences.
  • Click Privacy & Security from the left toolbar.
  • Scroll to the Cookies and Site Data section.

Click Cookies and Site Data on Firefox to clear cookies

Image Source

  • Click Manage Data…
  • In the Search field, type the name of the website causing the redirect loop.

Remove redirecting website in firefox to clear cookies

Image Source

  • Click Remove All Shown.
  • Click Save 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 the Customize icon then click Settings.

Click settings in chrome to clear cache

  • Click Privacy and security from the left toolbar.
  • Click Clear browsing data.
  • Set your time range, then click Clear Data.

Click clear data on Chrome to clear cache

Safari

  • Click Safari > Preferences.

click safari > preferences to clear cache in safari

  • Click Privacy.
  • Click Manage Website Data.

click manage website data to clear browser cache in safari

  • Click Remove All.
  • Click Remove Now.

click remove all and remove now to clear cache in safari

  • Click Done.

Firefox

  • Click Firefox > Preferences.
  • Click Privacy & Security from the left toolbar.
  • Scroll to the Cookies and Site Data section.

click cookies and site data to clear cache in firefox

Image Source

  • Click Clear Data…
  • Cookies and Site Data and Cached Web Content should both be check marked by default. Click Clear.

clear cached web content in firefox

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 Secure Sockets Layer (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’ve forced SSL on your site without 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 and renewed when needed. You can use an online tool like SSL Shopper, SSL Server Test, or Digicert, to test that your SSL configuration is installed, valid, and trusted in just a few minutes.

enter site URL in SSL shopper to check if SSL configuration is causing too many redirects errorn

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, Cloudflare has 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.

Cloudflare flexiblle SSL option can cause too many redirects error

Image Source

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 plugins allow 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 plugins. 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.
  • Select Plugins > Installed Plugins.
  • Check the box next to Plugin to select all your plugins.

Check box next to plugin to select all to temporarily deactivate

  • Choose Deactivate from the Bulk Actions drop-down menu, then click Apply.

Select deactivate from bulk action dropdown menu to fix too many redirects error

  • 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 your hypertext access file, or the .htaccess file, rename it, and create a new one. To do so, you can use a file manager like cPanel or via FTP client. The following steps are for cPanel specifically.

  • Go to File Manager and select your .htaccess file.
  • Right-click to rename it .htaccess_old. This is now your backup file.
  • Go to public_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]
</IfModule>
  • 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 your website 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.

New Call-to-action

Если вы видите ошибку Слишком много перенаправлений (ERR_TOO_MANY_REDIRECTS) в своем веб-браузере, значит что-то пошло не так. Также эта ошибка сопровождается сообщением Эта веб-страница имеет цикл перенаправления (This webpage has a redirect loop) и она блокирует загрузку сайта.

Ошибка Слишком много перенаправлений означает, что сайт продолжает циклично перенаправляться между разными адресами и это может никогда не прекратиться. Ваш браузер защищает вас от этого, разрешая только определенное количество перенаправлений (часто около десяти), прежде чем он «устанет» от этого и не выдаст данную ошибку.

Ошибка о цикличных перенаправлениях по-разному проявляется в разных браузерах:

Эта страница не работает (This page isn’t working)
{domain} перенаправил вас слишком много раз. ({domain} redirected you too many times.)
Или
Эта веб-страница имеет цикл перенаправления (This webpage has a redirect loop)
Попробуйте очистить ваши куки. (Try clearing your cookies.)
ERR_TOO_MANY_REDIRECTS

Google Chrome

Страница не перенаправляет должным образом (The page isn’t redirecting properly).
Произошла ошибка при подключении к {domain}. Эта проблема иногда может быть вызвана отключением или отказом принимать куки. (An error occured during a connection to {domain}. This problem can sometimes be caused by disabling or refusing to accept cookies.)

Mozilla Firefox

Safari не может открыть страницу (Safari Can’t Open the Page).
При попытке открыть {domain} произошло слишком много перенаправлений. Это может произойти, если вы открываете страницу, которая перенаправляется на другую страницу, которая затем перенаправляется на исходную страницу. (Too many redirects occurred trying to open {domain}. This might occur if you open a page that is redirected to open another page which is then redirected to open the original page.)

Safari

Очень часто это является результатом конфликтных перенаправлений, одно из которых пытается принудительно установить HTTPS (SSL) соединение, а другое – обратно HTTP (не-SSL), или между URL-адресами с www и без www.

Для таких CMS, ​​как WordPress или Magento, это решается приведением к общему конфигурации base_url или URL-адреса сайта в коде или базе данных с перенаправлением в файле .htaccess.

Как определить причину цикличного перенаправления

Вы можете следить за всеми перенаправлениями с помощью инструментов разработчика в браузере Firefox или Chrome. Эти инструменты обычно открываются нажатием клавиши F12 (или Ctrl+Shift+I). Откройте Сеть (Network), а затем перезагрузите страницу, на которой у вас возникла проблема.

После перезагрузки страницы вы увидите список перенаправлений. Проанализировав результаты, вы сможете найти «виновника» (если срабатывает перенаправление на одну и ту же страницу).

Основные типы перенаправления (код ответа состояния HTTP):

  • 301 редирект (постоянное перенаправление) – означает, что страница или элемент перемещен на постоянной основе, и браузер должен искать его в новом месте. Чаще всего записываются в файле .htaccess.
  • 302 перенаправление или редирект – это временное перенаправление, которое означает, что страница или элемент перемещен временно, и его адрес в будущем может измениться. Чаще всего записываются в коде веб-сайта.

Как исправить ошибку перенаправлений (редиректов)

Шаг №1: Очистить кэш и куки браузера

Очень часто циклические перенаправления могут вызываться файлами cookie в браузере, в которых закэшированы старые редиректы. Данные браузера, такие как история просмотров, кэш, файлы cookie и т.д., могут содержать ошибочные данные, которые вызывают ошибку ERR_TOO_MANY_REDIRECTS. Очистка этих данных – эффективный способ исправить ошибку. Чтобы очистить данные просмотра:

  • В Google Chrome нажмите Ctrl+Shift+Delete, выберите необходимые данные, время жизни данных и нажмите Очистить данные (clear data)
  • В Mozilla Firefox нажмите кнопку «Меню» и выберите «Параметры». Выберите Конфиденциальность, а затем очистить свою недавнюю историю (clear your recent history). Выберите Everything для диапазона времени, а затем нажмите Очистить сейчас (Clear Now).

После очистки данных браузера вы можете попробовать зайти на сайт и посмотреть, исчезла ли ошибка.

Шаг №2: Попробовать в других браузерах

Ошибка ERR_TOO_MANY_REDIRECTS может возникать только в браузере, который вы используете. Вы можете попробовать открыть тот же URL в другом браузере. Если ошибка не устраняется, значит проблема может возникать на стороне сервера.

Правильные настройки редиректов (перенаправлений)

Как мы уже упоминали выше, причиной ошибки могут быть неправильные настройки на вашем сайте. В основном, они касаются настроек редиректов в файле .htaccess. Данный файл – это файл конфигурации, который используется для изменения поведения сервера Apache для каждой папки на сайте или сервере. С его помощью можно редактировать только некоторые конфигурации Apache, хотя перенаправления обычно разрешается редактировать.

У вас может быть несколько файлов .htaccess, которые каскадно влияют на каталоги. Если у вас есть один .htaccess в родительском каталоге, и другой в подкаталоге, они оба будут влиять на этот подкаталог. Т.е., это может быть причиной конфликта между этими файлами на разных уровнях.

Ниже приведен ряд примеров перенаправления (редиректов) в файле .htaccess, которые обычно используются на сайтах.

Принудительный HTTPS

Приведенный ниже код сначала проверяет, поступил ли запрос на сервер с использованием HTTP или HTTPS. Если в запросе не использовался HTTPS, то конфигурация скажет браузеру перенаправить на HTTPS-версию того же веб-сайта и URL-адреса, которые были запрошены ранее:

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Принудительный HTTPS при использовании прокси-сервера

Вы можете использовать прокси-сервер, например, балансировщик нагрузки или веб-брандмауэр, для которого можно настроить использование SSL (HTTPS) на внешнем интерфейсе, но не на внутреннем. Чтобы это работало правильно, вам нужно проверять не только HTTPS в запросе, но и проверять, передал ли прокси-сервер исходный HTTPS-запрос на сервер, используя только HTTP. Код ниже проверяет, был ли запрос перенаправлен с HTTPS, и, если это так, не пытается дополнительно его перенаправлять:

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteCond %{HTTP:X-Forwarded-Proto} =http
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Перенаправление с HTTP на HTTPS в Nginx

Если на вашем веб-сервере работает Nginx, вы можете легко перенаправить весь ваш HTTP-трафик на HTTPS, добавив следующий код в файл конфигурации Nginx:

server {
 listen 80;
 server_name domain.com www.domain.com;
 return 301 https://domain.com$request_uri;
}

Замените domain.com на свой домен.

Принудительно без www

Следующий код в файле .htaccess проверяет, был ли запрошен сайт с www в начале доменного имени. Если www есть в URL, тогда он переписывает запрос и говорит браузеру перенаправить на доменное имя без www:

RewriteEngine On
RewriteCond %{HTTP_HOST} ^www. [NC] RewriteRule (.*) http://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Принудительно с www

Этот код в файле .htaccess проверяет, не было ли запрошено имя сайта с www в начале доменного имени. Если www не включен в URL, тогда он переписывает запрос и говорит браузеру перенаправить на www-версию домена:

RewriteEngine On
RewriteCond %{HTTP_HOST} !^www. [NC] RewriteRule (.*) http://www.%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Краткий итог

Если на вашем сайте есть редирект в файле .htaccess, что перенаправляет на URL, который не совпадает с тем, что находится в базе данных, вы можете получить ошибку в браузере о бесконечном цикле перенаправления (ERR_TOO_MANY_REDIRECTS), как описано выше.

Однако теперь вы знаете, как выглядят некоторые распространенные перенаправления в .htaccess. Также, с помощью данной статьи, вы сможете сами протестировать, найти причину ошибки, а также устранить ее самостоятельно.

Спасибо, что читаете нас!



  • 9562
  • Опубликовано 22/06/2019



  • Уроки программирования

В последнее время, когда я пытаюсь просмотреть App Store на моем iPhone, он показывает мне, что существует «слишком много HTTP (или HTTPS) перенаправлений». А потом, на днях это случилось и в Safari! Так в чем же дело?

Несколько читателей говорят нам, что Safari и / или их приложение в App Store не работает. В частности, когда они пытаются войти на сайт или открыть приложение, они получают сообщение об ошибке «Safari не может открыть страницу, потому что произошло слишком много перенаправлений!»

Эта ошибка может показывать слишком много перенаправлений HTTP или HTTPS перенаправления.

Слишком много HTTP-перенаправлений в App Store для iOS?

Если вы совершенно не можете получить доступ к App Store на вашем устройстве iOS; следуйте инструкциям ниже.

После выполнения каждого шага, пожалуйста, проверьте, решена ли проблема.

Принудительно закрыть приложение App Store

  1. Дважды нажмите кнопку «Домой» или проведите вверх по панели «Жесты дома»
  2. Найдите предварительный просмотр приложения для App Store
  3. Проведите предварительный просмотр приложения App Store в верхней части экрана.
  4. Перезагрузите ваше устройство
  5. Попробуйте снова запустить приложение App Store

Если закрытие приложения App Store не работает

  • Закройте все открытые приложения, дважды нажав кнопку «Домой» или проведя вверх по панели «Домашние жесты»
  • Проведите пальцем вверх от верхней части экрана все превью приложений
  • Делайте это, пока все, что вы видите, это ваш главный экран

Выйдите и вернитесь в iTunes & App Store

  1. Откройте Настройки> iTunes & App Store
  2. Нажмите на свой Apple ID
  3. Выберите Выйти
  4. Нажмите Войти

Если выход из системы и повторный вход не помогают

  1. Вернитесь в Настройки> iTunes & App Store
  2. Выйдите из своего Apple ID снова
  3. Откройте App Store
  4. Попробуйте скачать что-нибудь бесплатно
  5. Когда появится запрос на ввод вашего Apple ID, проигнорируйте это сообщение и вместо этого снова откройте « Настройки»> «iTunes & App Store» и войдите в систему, используя свой Apple ID.

Принудительно перезагрузите ваш iDevice

Слишком много HTTP-перенаправлений в Safari для iOS?

Принудительно закрыть приложение Safari

  1. Дважды нажмите кнопку «Домой» или проведите вверх по панели «Жесты дома»
  2. Найдите предварительный просмотр приложения для Safari
  3. Проведите предварительный просмотр приложения Safari в верхней части экрана.
  4. Перезагрузите ваше устройство
  5. Попробуйте снова запустить приложение Safari.

Если закрытие приложения Safari не работает

  • Закройте все открытые приложения, дважды нажав кнопку «Домой» или проведя вверх по панели «Домашние жесты»
  • Проведите пальцем вверх от верхней части экрана все превью приложений
  • Делайте это, пока все, что вы видите, это ваш главный экран

Очистить кэш Safari’s

Если очистка кэша Safari не помогла

  • Зайдите в Настройки> Safari
  • Прокрутите до раздела « Конфиденциальность и безопасность».
  • Разрешить Cookies, отключив Блокировать все Cookies

Временно отключить настройку для предотвращения межсайтового отслеживания

Запрос рабочего стола Safari на рабочем столе

  1. На точной странице, где вы получаете ошибку перенаправления, нажмите и удерживайте значок обновления
  2. Выберите Запрос рабочего стола
  3. Другой вариант — нажать кнопку « Поделиться».
  4. И выберите Запрос настольного сайта из общего листа

Почему Netflix Say ‘не может открыть страницу, слишком много перенаправлений?’

Некоторые пользователи сообщают, что они получают ту же ошибку с приложением Netflix

Для устройств iOS

  1. На главном экране нажмите Настройки
  2. Прокрутите вниз и нажмите Safari
  3. В разделе «Конфиденциальность и безопасность» отключите блокировку всех файлов cookie.
  4. Вернитесь на свою электронную почту и попробуйте ссылку сброса пароля снова

Для Mac

  1. Перейдите в Safari> Настройки
  2. Выберите Конфиденциальность
  3. В разделе «Файлы cookie» и данные веб-сайта выберите « Управление данными веб-сайта».
  4. Поиск Netflix
  5. Выберите Удалить
  6. Нажмите Удалить сейчас
  7. После удаления данных веб-сайта Netflix закройте Safari и попробуйте снова Netflix

Слишком много HTTP-перенаправлений в Safari для Mac?

  1. Открытое Сафари
  2. Выберите Safari> Настройки
  3. Нажмите значок конфиденциальности
  4. Нажмите Управление данными сайта
  5. Нажмите « Удалить все» или используйте поле «Поиск», чтобы найти имя перенаправляющего веб-сайта, затем выберите веб-сайт и нажмите « Удалить сейчас».
  6. Нажмите «Готово», затем закройте настройки Safari.

Три способа решения ошибки «Сайт выполнил переадресацию слишком много раз»

12.12.2022

Не можете зайти на сайт, потому что браузер выдает сообщение «Страница недоступна. Сайт выполнил переадресацию слишком много раз. Удалите файлы Cookie. ERR_TOO_MANY_REDIRECTS»? Как поступать в такой ситуации и всё-таки открыть нужный сайт?

ошибка "страница недоступна"

Image Source

Too Many Redirects Safari

too many redirects safari

Image Source

Too Many Redirects Firefox

too many redirects firefox

Image Source

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

  1. Clear cookies on the redirecting website.
  2. Clear your browser cache.
  3. Ensure your SSL certificate is installed correctly.
  4. Evaluate your third-party services and plugins.
  5. Reset your htaccess file.
  6. Contact your hosting provider.

These steps apply to any website, no matter what website builder or content 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 out How to Fix the Redirect Loop Error in WordPress to 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 the Customize icon then click Settings.

Navigate to setting to clear cookies on Chrome

  • Click Privacy and security from the left toolbar.
  • Click Cookies and other site data.

Click Cookies and other site data on Chrome

  • Scroll down and click See all cookies and site data.

Click see all cookies and other data on Chrome

  • At the top right, search for the website’s name.
  • To the right of the site, click Remove.

Click remove redirecting loop website on Chrome

Safari

  • Click Safari > Preferences.

click Safari > Preferences to clear cookies

  • Click Privacy.
  • Click Manage Website Data.

Click manage website data to clear cookies on safari

  • Use the Search field to find the name of the website causing the redirect loop.
  • Select the site and click Remove.

Remove redirecting website on Safari

  • Click Done.

Firefox

  • Click Firefox > Preferences.
  • Click Privacy & Security from the left toolbar.
  • Scroll to the Cookies and Site Data section.

Click Cookies and Site Data on Firefox to clear cookies

Image Source

  • Click Manage Data…
  • In the Search field, type the name of the website causing the redirect loop.

Remove redirecting website in firefox to clear cookies

Image Source

  • Click Remove All Shown.
  • Click Save 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 the Customize icon then click Settings.

Click settings in chrome to clear cache

  • Click Privacy and security from the left toolbar.
  • Click Clear browsing data.
  • Set your time range, then click Clear Data.

Click clear data on Chrome to clear cache

Safari

  • Click Safari > Preferences.

click safari > preferences to clear cache in safari

  • Click Privacy.
  • Click Manage Website Data.

click manage website data to clear browser cache in safari

  • Click Remove All.
  • Click Remove Now.

click remove all and remove now to clear cache in safari

  • Click Done.

Firefox

  • Click Firefox > Preferences.
  • Click Privacy & Security from the left toolbar.
  • Scroll to the Cookies and Site Data section.

click cookies and site data to clear cache in firefox

Image Source

  • Click Clear Data…
  • Cookies and Site Data and Cached Web Content should both be check marked by default. Click Clear.

clear cached web content in firefox

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 Secure Sockets Layer (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’ve forced SSL on your site without 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 and renewed when needed. You can use an online tool like SSL Shopper, SSL Server Test, or Digicert, to test that your SSL configuration is installed, valid, and trusted in just a few minutes.

enter site URL in SSL shopper to check if SSL configuration is causing too many redirects errorn

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, Cloudflare has 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.

Cloudflare flexiblle SSL option can cause too many redirects error

Image Source

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 plugins allow 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 plugins. 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.
  • Select Plugins > Installed Plugins.
  • Check the box next to Plugin to select all your plugins.

Check box next to plugin to select all to temporarily deactivate

  • Choose Deactivate from the Bulk Actions drop-down menu, then click Apply.

Select deactivate from bulk action dropdown menu to fix too many redirects error

  • 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 your hypertext access file, or the .htaccess file, rename it, and create a new one. To do so, you can use a file manager like cPanel or via FTP client. The following steps are for cPanel specifically.

  • Go to File Manager and select your .htaccess file.
  • Right-click to rename it .htaccess_old. This is now your backup file.
  • Go to public_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]
</IfModule>
  • 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 your website 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.

New Call-to-action

Если вы видите ошибку Слишком много перенаправлений (ERR_TOO_MANY_REDIRECTS) в своем веб-браузере, значит что-то пошло не так. Также эта ошибка сопровождается сообщением Эта веб-страница имеет цикл перенаправления (This webpage has a redirect loop) и она блокирует загрузку сайта.

Ошибка Слишком много перенаправлений означает, что сайт продолжает циклично перенаправляться между разными адресами и это может никогда не прекратиться. Ваш браузер защищает вас от этого, разрешая только определенное количество перенаправлений (часто около десяти), прежде чем он «устанет» от этого и не выдаст данную ошибку.

Ошибка о цикличных перенаправлениях по-разному проявляется в разных браузерах:

Эта страница не работает (This page isn’t working)
{domain} перенаправил вас слишком много раз. ({domain} redirected you too many times.)
Или
Эта веб-страница имеет цикл перенаправления (This webpage has a redirect loop)
Попробуйте очистить ваши куки. (Try clearing your cookies.)
ERR_TOO_MANY_REDIRECTS

Google Chrome

Страница не перенаправляет должным образом (The page isn’t redirecting properly).
Произошла ошибка при подключении к {domain}. Эта проблема иногда может быть вызвана отключением или отказом принимать куки. (An error occured during a connection to {domain}. This problem can sometimes be caused by disabling or refusing to accept cookies.)

Mozilla Firefox

Safari не может открыть страницу (Safari Can’t Open the Page).
При попытке открыть {domain} произошло слишком много перенаправлений. Это может произойти, если вы открываете страницу, которая перенаправляется на другую страницу, которая затем перенаправляется на исходную страницу. (Too many redirects occurred trying to open {domain}. This might occur if you open a page that is redirected to open another page which is then redirected to open the original page.)

Safari

Очень часто это является результатом конфликтных перенаправлений, одно из которых пытается принудительно установить HTTPS (SSL) соединение, а другое – обратно HTTP (не-SSL), или между URL-адресами с www и без www.

Для таких CMS, ​​как WordPress или Magento, это решается приведением к общему конфигурации base_url или URL-адреса сайта в коде или базе данных с перенаправлением в файле .htaccess.

Как определить причину цикличного перенаправления

Вы можете следить за всеми перенаправлениями с помощью инструментов разработчика в браузере Firefox или Chrome. Эти инструменты обычно открываются нажатием клавиши F12 (или Ctrl+Shift+I). Откройте Сеть (Network), а затем перезагрузите страницу, на которой у вас возникла проблема.

После перезагрузки страницы вы увидите список перенаправлений. Проанализировав результаты, вы сможете найти «виновника» (если срабатывает перенаправление на одну и ту же страницу).

Основные типы перенаправления (код ответа состояния HTTP):

  • 301 редирект (постоянное перенаправление) – означает, что страница или элемент перемещен на постоянной основе, и браузер должен искать его в новом месте. Чаще всего записываются в файле .htaccess.
  • 302 перенаправление или редирект – это временное перенаправление, которое означает, что страница или элемент перемещен временно, и его адрес в будущем может измениться. Чаще всего записываются в коде веб-сайта.

Как исправить ошибку перенаправлений (редиректов)

Шаг №1: Очистить кэш и куки браузера

Очень часто циклические перенаправления могут вызываться файлами cookie в браузере, в которых закэшированы старые редиректы. Данные браузера, такие как история просмотров, кэш, файлы cookie и т.д., могут содержать ошибочные данные, которые вызывают ошибку ERR_TOO_MANY_REDIRECTS. Очистка этих данных – эффективный способ исправить ошибку. Чтобы очистить данные просмотра:

  • В Google Chrome нажмите Ctrl+Shift+Delete, выберите необходимые данные, время жизни данных и нажмите Очистить данные (clear data)
  • В Mozilla Firefox нажмите кнопку «Меню» и выберите «Параметры». Выберите Конфиденциальность, а затем очистить свою недавнюю историю (clear your recent history). Выберите Everything для диапазона времени, а затем нажмите Очистить сейчас (Clear Now).

После очистки данных браузера вы можете попробовать зайти на сайт и посмотреть, исчезла ли ошибка.

Шаг №2: Попробовать в других браузерах

Ошибка ERR_TOO_MANY_REDIRECTS может возникать только в браузере, который вы используете. Вы можете попробовать открыть тот же URL в другом браузере. Если ошибка не устраняется, значит проблема может возникать на стороне сервера.

Правильные настройки редиректов (перенаправлений)

Как мы уже упоминали выше, причиной ошибки могут быть неправильные настройки на вашем сайте. В основном, они касаются настроек редиректов в файле .htaccess. Данный файл – это файл конфигурации, который используется для изменения поведения сервера Apache для каждой папки на сайте или сервере. С его помощью можно редактировать только некоторые конфигурации Apache, хотя перенаправления обычно разрешается редактировать.

У вас может быть несколько файлов .htaccess, которые каскадно влияют на каталоги. Если у вас есть один .htaccess в родительском каталоге, и другой в подкаталоге, они оба будут влиять на этот подкаталог. Т.е., это может быть причиной конфликта между этими файлами на разных уровнях.

Ниже приведен ряд примеров перенаправления (редиректов) в файле .htaccess, которые обычно используются на сайтах.

Принудительный HTTPS

Приведенный ниже код сначала проверяет, поступил ли запрос на сервер с использованием HTTP или HTTPS. Если в запросе не использовался HTTPS, то конфигурация скажет браузеру перенаправить на HTTPS-версию того же веб-сайта и URL-адреса, которые были запрошены ранее:

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Принудительный HTTPS при использовании прокси-сервера

Вы можете использовать прокси-сервер, например, балансировщик нагрузки или веб-брандмауэр, для которого можно настроить использование SSL (HTTPS) на внешнем интерфейсе, но не на внутреннем. Чтобы это работало правильно, вам нужно проверять не только HTTPS в запросе, но и проверять, передал ли прокси-сервер исходный HTTPS-запрос на сервер, используя только HTTP. Код ниже проверяет, был ли запрос перенаправлен с HTTPS, и, если это так, не пытается дополнительно его перенаправлять:

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteCond %{HTTP:X-Forwarded-Proto} =http
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Перенаправление с HTTP на HTTPS в Nginx

Если на вашем веб-сервере работает Nginx, вы можете легко перенаправить весь ваш HTTP-трафик на HTTPS, добавив следующий код в файл конфигурации Nginx:

server {
 listen 80;
 server_name domain.com www.domain.com;
 return 301 https://domain.com$request_uri;
}

Замените domain.com на свой домен.

Принудительно без www

Следующий код в файле .htaccess проверяет, был ли запрошен сайт с www в начале доменного имени. Если www есть в URL, тогда он переписывает запрос и говорит браузеру перенаправить на доменное имя без www:

RewriteEngine On
RewriteCond %{HTTP_HOST} ^www. [NC] RewriteRule (.*) http://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Принудительно с www

Этот код в файле .htaccess проверяет, не было ли запрошено имя сайта с www в начале доменного имени. Если www не включен в URL, тогда он переписывает запрос и говорит браузеру перенаправить на www-версию домена:

RewriteEngine On
RewriteCond %{HTTP_HOST} !^www. [NC] RewriteRule (.*) http://www.%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Краткий итог

Если на вашем сайте есть редирект в файле .htaccess, что перенаправляет на URL, который не совпадает с тем, что находится в базе данных, вы можете получить ошибку в браузере о бесконечном цикле перенаправления (ERR_TOO_MANY_REDIRECTS), как описано выше.

Однако теперь вы знаете, как выглядят некоторые распространенные перенаправления в .htaccess. Также, с помощью данной статьи, вы сможете сами протестировать, найти причину ошибки, а также устранить ее самостоятельно.

Спасибо, что читаете нас!



  • 9562
  • Опубликовано 22/06/2019



  • Уроки программирования

В последнее время, когда я пытаюсь просмотреть App Store на моем iPhone, он показывает мне, что существует «слишком много HTTP (или HTTPS) перенаправлений». А потом, на днях это случилось и в Safari! Так в чем же дело?

Несколько читателей говорят нам, что Safari и / или их приложение в App Store не работает. В частности, когда они пытаются войти на сайт или открыть приложение, они получают сообщение об ошибке «Safari не может открыть страницу, потому что произошло слишком много перенаправлений!»

Эта ошибка может показывать слишком много перенаправлений HTTP или HTTPS перенаправления.

Слишком много HTTP-перенаправлений в App Store для iOS?

Если вы совершенно не можете получить доступ к App Store на вашем устройстве iOS; следуйте инструкциям ниже.

После выполнения каждого шага, пожалуйста, проверьте, решена ли проблема.

Принудительно закрыть приложение App Store

  1. Дважды нажмите кнопку «Домой» или проведите вверх по панели «Жесты дома»
  2. Найдите предварительный просмотр приложения для App Store
  3. Проведите предварительный просмотр приложения App Store в верхней части экрана.
  4. Перезагрузите ваше устройство
  5. Попробуйте снова запустить приложение App Store

Если закрытие приложения App Store не работает

  • Закройте все открытые приложения, дважды нажав кнопку «Домой» или проведя вверх по панели «Домашние жесты»
  • Проведите пальцем вверх от верхней части экрана все превью приложений
  • Делайте это, пока все, что вы видите, это ваш главный экран

Выйдите и вернитесь в iTunes & App Store

  1. Откройте Настройки> iTunes & App Store
  2. Нажмите на свой Apple ID
  3. Выберите Выйти
  4. Нажмите Войти

Если выход из системы и повторный вход не помогают

  1. Вернитесь в Настройки> iTunes & App Store
  2. Выйдите из своего Apple ID снова
  3. Откройте App Store
  4. Попробуйте скачать что-нибудь бесплатно
  5. Когда появится запрос на ввод вашего Apple ID, проигнорируйте это сообщение и вместо этого снова откройте « Настройки»> «iTunes & App Store» и войдите в систему, используя свой Apple ID.

Принудительно перезагрузите ваш iDevice

Слишком много HTTP-перенаправлений в Safari для iOS?

Принудительно закрыть приложение Safari

  1. Дважды нажмите кнопку «Домой» или проведите вверх по панели «Жесты дома»
  2. Найдите предварительный просмотр приложения для Safari
  3. Проведите предварительный просмотр приложения Safari в верхней части экрана.
  4. Перезагрузите ваше устройство
  5. Попробуйте снова запустить приложение Safari.

Если закрытие приложения Safari не работает

  • Закройте все открытые приложения, дважды нажав кнопку «Домой» или проведя вверх по панели «Домашние жесты»
  • Проведите пальцем вверх от верхней части экрана все превью приложений
  • Делайте это, пока все, что вы видите, это ваш главный экран

Очистить кэш Safari’s

Если очистка кэша Safari не помогла

  • Зайдите в Настройки> Safari
  • Прокрутите до раздела « Конфиденциальность и безопасность».
  • Разрешить Cookies, отключив Блокировать все Cookies

Временно отключить настройку для предотвращения межсайтового отслеживания

Запрос рабочего стола Safari на рабочем столе

  1. На точной странице, где вы получаете ошибку перенаправления, нажмите и удерживайте значок обновления
  2. Выберите Запрос рабочего стола
  3. Другой вариант — нажать кнопку « Поделиться».
  4. И выберите Запрос настольного сайта из общего листа

Почему Netflix Say ‘не может открыть страницу, слишком много перенаправлений?’

Некоторые пользователи сообщают, что они получают ту же ошибку с приложением Netflix

Для устройств iOS

  1. На главном экране нажмите Настройки
  2. Прокрутите вниз и нажмите Safari
  3. В разделе «Конфиденциальность и безопасность» отключите блокировку всех файлов cookie.
  4. Вернитесь на свою электронную почту и попробуйте ссылку сброса пароля снова

Для Mac

  1. Перейдите в Safari> Настройки
  2. Выберите Конфиденциальность
  3. В разделе «Файлы cookie» и данные веб-сайта выберите « Управление данными веб-сайта».
  4. Поиск Netflix
  5. Выберите Удалить
  6. Нажмите Удалить сейчас
  7. После удаления данных веб-сайта Netflix закройте Safari и попробуйте снова Netflix

Слишком много HTTP-перенаправлений в Safari для Mac?

  1. Открытое Сафари
  2. Выберите Safari> Настройки
  3. Нажмите значок конфиденциальности
  4. Нажмите Управление данными сайта
  5. Нажмите « Удалить все» или используйте поле «Поиск», чтобы найти имя перенаправляющего веб-сайта, затем выберите веб-сайт и нажмите « Удалить сейчас».
  6. Нажмите «Готово», затем закройте настройки Safari.

Три способа решения ошибки «Сайт выполнил переадресацию слишком много раз»

12.12.2022

Не можете зайти на сайт, потому что браузер выдает сообщение «Страница недоступна. Сайт выполнил переадресацию слишком много раз. Удалите файлы Cookie. ERR_TOO_MANY_REDIRECTS»? Как поступать в такой ситуации и всё-таки открыть нужный сайт?

ошибка "страница недоступна"

Оговорюсь сразу: универсального решения в данном случае не существует, потому что причина ошибки ERR_TOO_MANY_REDIRECTS может быть разная. Однако поделюсь тем, какие действия можно предпринять, чтобы эту ошибку исправить.

Решение 1. Чистим куки

Для начала воспользуемся подсказкой самого браузера и удалим файлы cookie. Но почистим куки не для всех сайтов одним махом, потому что это всё равно что из пушки палить по воробьям, а прицельно только для проблемного сайта. Покажу на примере Google Chrome.

Открываем Настройки браузера -> Конфиденциальность и безопасность -> Файлы cookie и другие данные сайтов.

выбор файлов cookie

На открывшейся страничке выбираем  пункт «Посмотреть все разрешения и данные сайтов».

разрешения сайтов в настройках браузера

Вы увидите список ресурсов интернет, на которые вы когда-либо заходили.  В правом верхнем углу вы найдете поисковое окно.

  1. Наберите в нем домен сайта, который у вас недоступен и выполнил слишком много переадресаций.
  2. Нажмите иконку корзины рядом с названием сайта (поиск происходит автоматически), чтобы очистить для него все сохраненные в браузере cookie.
  3. Перезагрузите браузер

чистка cookie в браузере

Если причина переадресаций и недоступности страница была именно в вашем браузере из-за устаревших cookie, то после описанных действий сайт откроется нормально.

Решение 2. Используем другой браузер

Если чистка куки не помогла, либо вы не хотите возиться с их удалением, есть куда более простой способ решить проблему.

Откройте сайт в любом другом установленном у вас браузере. В 90% случаев он откроется нормально – проверено лично!

смена браузера как способ решения проблемы

Иногда ошибка «Сайт выполнил переадресацию слишком много раз» возникает из-за того, что администратор сайта, на который вы пытаетесь попасть, внес какие-то изменения в конфигурацию сервера (неверное настроил редиректы, криво установил SSL-сертификат и пр.), что обычно приводит к циклическим переадресациям в браузере при попытке попасть на страницу и её недоступности как следствие этого.

При этом что интересно: сайт может нормально открываться в Опере, например, и не открываться в то же самое время в Хроме. Именно поэтому после всех внесенных на сервере изменений работоспособность ресурса надо тестировать во всех популярных браузерах. К сожалению, далеко не все владельцы сайтов придерживаются данного правила, что и приводит зачастую к проблемам.

Если Решение №2 не помогло, и сайт по-прежнему не открывается ни в одном из браузеров, то проблема не на вашей стороне и решить самостоятельно её не получится. В этом случае выходом из ситуации будет сообщить админу или техподдержке сайта о том, что их ресурс недоступен. Также не забудьте сообщить им характер ошибки: ERR_TOO_MANY_REDIRECTS. Администрация внесет нужные правки в конфигурацию сервера, и сайт снова станет доступен.

Расшифровку других ошибок, которые часто выдают сайты при попытке попасть на них через браузер, вы найдете тут: https://webtous.ru/poleznye-sovety/rasprostranennye-oshibki-sajtov-i-ix-znachenie.html

Похожие публикации:

  • 10 способов продлить заряд аккумулятора
  • Срочно! Отключаем передачу информации из WhatsApp в Facebook
  • Что означает запись «Этим браузером управляет ваша организация» в Гугл Хроме?
  • В чем разница между JPEG и JPG?
  • VSync в играх: что это и нужно ли включать эту опцию?

Понравилось? Поделитесь с друзьями!

фото автора
Сергей Сандаков, 42 года.
С 2011 г. пишу обзоры полезных онлайн сервисов и сайтов, программ для ПК.
Интересуюсь всем, что происходит в Интернет, и с удовольствием рассказываю об этом своим читателям.

We come across a lot of different errors here at Kinsta, and ERR_TOO_MANY_REDIRECTS (also known as a redirect loop) is one we see on a regular basis.

Typically this occurs after a recent change on your website, a misconfiguration of redirects on your server, or wrong settings with third-party services. But don’t worry, this error is fairly easy to fix.

Check out the recommendations below on how to fix this error and get your site back up and running.

What is the ERR_TOO_MANY_REDIRECTS Error?

The ERR_TOO_MANY_REDIRECTS error is pretty much what it sounds like: something is causing too many redirects, sending your website into an infinite redirection loop.

Essentially the site is stuck (such as URL 1 points to URL 2 and URL 2 points back to URL 1, or the domain has redirected you too many times) and unlike some other errors, these rarely resolve themselves and will probably need you to take action to fix it.

You might have also come across the error “request exceeded the limit of 10 internal redirects due to probable configuration error“.

Error Code ERR_TOO_MANY_REDIRECTS
Error Type Browser error/code error
Error Variations This page isn’t working. domain.com redirected you too many times.
The page isn’t redirecting properly
This page isn’t working right now
Safari Can’t Open the Page
Error Causes Misconfigured WordPress settings/plugins
Issues with browser’s cache/cookies.
Issues with third-party services
Bad HTTPS settings
Bad server settings

The ERR_TOO_MANY_REDIRECTS error

The ERR_TOO_MANY_REDIRECTS error occurs as a result of a misconfiguration of redirects on your server, or incorrect settings with third-party services. This error is essentially what it implies: a loop of too many redirects is causing your website to be stuck in an endless cycle.

ERR_TOO_MANY_REDIRECTS: What Does It Look Like?

There are a couple of different variations of this error depending upon the browser you’re running.

Google Chrome

In Google Chrome this error will show as ERR_TOO_MANY_REDIRECTS (as seen below) or This webpage has a redirect loop problem.

This page isn’t working. domain.com redirected you too many times.

ERR_TOO_MANY_REDIRECTS in Google Chrome
Сергей Сандаков, 42 года.
С 2011 г. пишу обзоры полезных онлайн сервисов и сайтов, программ для ПК.
Интересуюсь всем, что происходит в Интернет, и с удовольствием рассказываю об этом своим читателям.

We come across a lot of different errors here at Kinsta, and ERR_TOO_MANY_REDIRECTS (also known as a redirect loop) is one we see on a regular basis.

Typically this occurs after a recent change on your website, a misconfiguration of redirects on your server, or wrong settings with third-party services. But don’t worry, this error is fairly easy to fix.

Check out the recommendations below on how to fix this error and get your site back up and running.

What is the ERR_TOO_MANY_REDIRECTS Error?

The ERR_TOO_MANY_REDIRECTS error is pretty much what it sounds like: something is causing too many redirects, sending your website into an infinite redirection loop.

Essentially the site is stuck (such as URL 1 points to URL 2 and URL 2 points back to URL 1, or the domain has redirected you too many times) and unlike some other errors, these rarely resolve themselves and will probably need you to take action to fix it.

You might have also come across the error “request exceeded the limit of 10 internal redirects due to probable configuration error“.

Error Code ERR_TOO_MANY_REDIRECTS
Error Type Browser error/code error
Error Variations This page isn’t working. domain.com redirected you too many times.
The page isn’t redirecting properly
This page isn’t working right now
Safari Can’t Open the Page
Error Causes Misconfigured WordPress settings/plugins
Issues with browser’s cache/cookies.
Issues with third-party services
Bad HTTPS settings
Bad server settings

The ERR_TOO_MANY_REDIRECTS error

The ERR_TOO_MANY_REDIRECTS error occurs as a result of a misconfiguration of redirects on your server, or incorrect settings with third-party services. This error is essentially what it implies: a loop of too many redirects is causing your website to be stuck in an endless cycle.

ERR_TOO_MANY_REDIRECTS: What Does It Look Like?

There are a couple of different variations of this error depending upon the browser you’re running.

Google Chrome

In Google Chrome this error will show as ERR_TOO_MANY_REDIRECTS (as seen below) or This webpage has a redirect loop problem.

This page isn’t working. domain.com redirected you too many times.

ERR_TOO_MANY_REDIRECTS in Google Chrome

ERR_TOO_MANY_REDIRECTS in Google Chrome

(Check out how to fix Chrome’s ERR_CACHE_MISS error).

Mozilla Firefox

In Mozilla Firefox it will show as The page isn’t redirecting properly (as seen below).

An error occured during a connection to domain.com. This problem can sometimes be caused by disabling or refusing to accept cookies.

ERR_TOO_MANY_REDIRECTS in Firefox

ERR_TOO_MANY_REDIRECTS in Mozilla Firefox

Microsoft Edge

In Microsoft Edge, it will simply show as This page isn’t working right now (as seen below).

Domain.com redirected you too many times.

ERR_TOO_MANY_REDIRECTS in Microsoft Edge

ERR_TOO_MANY_REDIRECTS in Microsoft Edge

Safari

In Safari, it will show as Safari Can’t Open the Page (as seen below).

Too many redirects occurred trying to open “domain.com.” This might occur if you open a page that is redirected to open another page which is then redirected to open the original page.

ERR_TOO_MANY_REDIRECTS error in Safari

ERR_TOO_MANY_REDIRECTS error in Safari

What Causes the ERR_TOO_MANY_REDIRECTS Error?

This error happens when the browser can’t establish a connection between the initial page and the destination page in a redirect. The main causes can be:

  • Misconfigured WordPress settings
  • Misconfigured WordPress plugin.
  • Misconfigured server settings.
  • Incorrect HTTPS settings.
  • Issues with the browser’s cache/cookies.
  • Issues with third-party services (e.g. CDNs).
  • Improper website or domain migration.

How To Fix the ERR_TOO_MANY_REDIRECTS Error?

Here are some recommendations and things to check to fix the error (sorted in order by most common reasons we see):

1. Delete Cookies on That Specific Site

Google and Mozilla both in fact recommend right below the error to “try clearing your cookies.” Cookies can sometimes contain faulty data in which could cause the ERR_TOO_MANY_REDIRECTS error. This is one recommendation you can try even if you’re encountering the error on a site you don’t own.

Due to the fact that cookies retain your “logged in” status on sites and other settings, we recommend simply deleting the cookie(s) on the site that is having the problem. This way you won’t impact any of your other sessions or websites that you frequently visit.

Follow the steps below to delete a cookie on a specific website in Google Chrome.

Step 1

In Google Chrome click on the three small dots in the upper right-hand corner. Then click on “Settings.”

Chrome settings

Chrome settings

Step 2

Scroll down and click on “Advanced.”

Chrome advanced settings

Chrome advanced settings

Step 3

Then click on “Content settings.”

Chrome content settings

Chrome content settings

Step 4

Click on “Cookies.”

Chrome cookies

Chrome cookies

Step 5

Then click on “See all cookies and site data.”

Chrome see all cookies

Chrome “see all cookies”

Step 6

Search for the site (domain) where you are encountering the ERR_TOO_MANY_REDIRECTS error. You can then delete the cookie(s) currently stored on your computer for that domain. Then try visiting the site again.

Delete cookie in Chrome

Delete cookie in Chrome

2. Clear Server, Proxy, and Browser Cache

Due to the fact that redirect loops are responses that can be cached, it’s always recommended to try clearing the cache on your WordPress site, the server, third-party proxy services, and even your browser if necessary.

Clear WordPress Site Cache

Depending upon the type of redirect loop, you might still be able to gain access to your WordPress admin dashboard. In this case, you can easily clear the cache within the settings of your caching plugin. Here are a couple of quick links on how to clear WordPress cache with popular plugins:

  • Clear Cache with Cache Enabler
  • Clear Cache with W3 Total Cache
  • Clear Cache with Super Cache

If you’re a Kinsta client, you can easily clear your cache from the WordPress admin toolbar.

Clear Kinsta cache from WordPress admin

Clear Kinsta cache from WordPress admin

Clear Server Cache

If you can’t access WordPress admin, many WordPress hosts have their own control panel tools for clearing the cache on your WordPress site.

If you’re a Kinsta client, you can manually clear WordPress cache from within the MyKinsta dashboard. Here are the steps:

Within the dashboard, click on WordPress Sites in the left sidebar navigation.

Click on your site name in the sites list and click on the Tools tab.

Click the Clear cache button to clear all cache.

Clear cache on the Tools tab in MyKinsta.

Clearing the cache on the Tools tab in MyKinsta.

Clear Proxy Cache

If you’re using a third-party reverse-proxy service such as Cloudflare or Sucuri, it can also be beneficial to clear the cache on their side.

Cloudflare

To purge Cloudflare cache, login to their dashboard, click into “Caching” and click on “Purge Everything.”

Purge cache

Sucuri

To purge Sucuri cache, login to their dashboard, go to “Performance” and click on “Clear Cache.”

Clear Sucuri cache

Clear Sucuri cache

Clear Browser Cache

If you want to check and see if it might be your browser cache, without clearing your cache, you can always open up your browser in incognito mode. Or test another browser and see if you still see the ERR_TOO_MANY_REDIRECTS error.

Open Chrome in Incognito mode

Open Chrome in Incognito mode

If you determine it is being caused by your browser cache, you can then clear it. Below are instructions on how to do it in various browsers:

  • How to Force Refresh a Single Page for All Browsers
  • How to Clear Browser Cache for Google Chrome
  • How to Clear Browser Cache for Mozilla Firefox
  • How to Clear Browser Cache for Safari
  • How to Clear Browser Cache for Internet Explorer
  • How to Clear Browser Cache for Microsoft Edge
  • How to Clear Browser Cache for Opera

3. Determine Nature of Redirect Loop

If clearing the cache didn’t work, then you’ll want to see if you can determine the nature of the redirect loop. Our free online Redirect Checker tool can help provide some further analysis into what might be going on. This could also be done via cURL.

For example, on the site below, it has a 301 redirect loop back to itself, which is causing a large chain of faulty redirects. You can follow all the redirects and determine whether or not it’s looping back to itself, or perhaps is an HTTP to HTTPS loop in which we’ll discuss how to solve that further below.

Too many redirects

Too many redirects

The Redirect Path Chrome extension can also be very useful and provides insights into all of the redirects happening on your site (specific URL or page.

Redirect Path extension

Redirect Path extension

4. Check Your HTTPS Settings

Another thing to check is your HTTPS settings. A lot of times we’ve seen ERR_TOO_MANY_REDIRECTS occur when someone has just migrated their WordPress site to HTTPS and either didn’t finish or set up something incorrectly.

Don’t Force HTTPS Without an SSL Certificate

This is by far the most common reason we see on a regular basis. If you force your WordPress site to load over HTTPS without first installing an SSL certificate, you’ll instantly throw your site into a redirection loop. To fix this, simply install an SSL certificate on your WordPress site.

It’s also recommended to run an SSL check. SSL/TLS certificates require not only your main certificate but also what they call intermediate certificates (chain) to also be installed. These need to be set up properly.

We recommend using the free SSL check tool from Qualys SSL Labs. It is very reliable and we use it for all Kinsta clients when verifying certificates. Simply head over to their SSL check tool, input your domain into the Hostname field and click on “Submit.” You can also select the option to hide public results if you prefer. It could take a minute or two to scan your site’s SSL/TLS configuration on your web server.

SSL check

SSL test

Don’t Use an SSL Plugin, Update your Hard-coded Links

There are some free SSL WordPress plugins, such as the Really Simple SSL plugin that will help you automatically redirect to HTTPS. However, we don’t recommend this method as a permanent solution because third-party plugins can always introduce another layer of problems and compatibility issues. It’s a good temporary solution, but you should really update your hard-coded HTTP links.

We have a great tutorial with 4 easy ways to do a search and replace in WordPress. If you’re a Kinsta client, you can always reach out to our support team to do this for you as well.

Check HTTP to HTTPS Redirects on Server

It could very well be that perhaps the HTTPS redirect rules on your server were misconfigured.

Redirect HTTP to HTTPS in Nginx

If your web server is running Nginx, you can easily redirect all of your HTTP traffic to HTTPS by adding the following code to your Nginx config file. This is the recommended method for redirecting WordPress running on Nginx.

server { listen 80; server_name domain.com www.domain.com; return 301 https://domain.com$request_uri; }

We use Nginx for everyone here at Kinsta. The great news is that you don’t have to worry about this. If you need to add a redirect simply open up a quick support ticket and let us know which domain you need to be redirected. We then add it to the Nginx config for you.

Check Out Our Video Guide to Redirects

Redirect HTTP to HTTPS in Apache

If your web server is running Apache, you can easily redirect all of your HTTP traffic to HTTPS by adding the following code to your .htaccess file. This is the recommended method for redirecting WordPress running on Apache.

RewriteEngine On
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

Check For Too Many HTTPS Redirects

Perhaps you simply have too many HTTPS redirects. You can easily check your site to see how many redirects it’s using with a tool like Redirect Checker. Here is an example below of redirects that are not set up correctly which are easily spottable using an online tool. You can see that there are duplicate HTTPS redirects happening on both the www and non-www versions.

redirects not setup correctly

Redirects

5. Check Third-Party Services

ERR_TOO_MANY_REDIRECTS is also often commonly caused by reverse-proxy services such as Cloudflare. This usually happens when their Flexible SSL option is enabled and you already have an SSL certificate installed with your WordPress host. Why? Because, when flexible is selected, all requests to your hosting server are sent over HTTP. Your host server most likely already has a redirect in place from HTTP to HTTPS, and therefore a redirect loop occurs.

To fix this you need to change the Cloudflare Crypto settings from Flexible to either Full or Full (strict). If you’re a Kinsta client, make sure to also check out our steps on how to install an SSL certificate while using Cloudflare.

Cloudflare full

Set Cloudflare crypto level to full

You can use their Always Use HTTPS page rule to redirect all users to HTTPS without creating a loop. Another thing to watch out for with Cloudflare is their forwarding URL redirection rules. Be careful not to create a redirect where the domain points to itself as a destination. This can cause an infinite redirect error, and the affected URLs will not be able to resolve.

If you’re using StackPath, they have an option called “Origin Pull Protocol” that needs to be set to HTTPS only.

Using Cloudflare DNS Only

If you only want to use Cloudflare’s DNS, and not their proxy/WAF service, then you should make sure your DNS records are set to “DNS Only.” The clouds will appear as “grey” instead of “orange.” You configure this under the “DNS” tab in the Cloudflare control panel.

Cloudflare DNS only

Cloudflare DNS only

6. Check Your WordPress Site Settings

Another thing to check is your WordPress site settings. There are two different fields you’ll want to ensure are set correctly, and not pointing at a wrong domain or are mismatched. Another common mistake is that you’re not using the correct prefix to match the rest of your site, www or non-www. Sometimes people migrate hosts, or change domains and these can get changed without you realizing it.

  • WordPress Address (URL): The address to reach your blog.
  • Site Address (URL): The address of your WordPress core files.

Both should match unless you are giving WordPress its own directory.

WordPress address

WordPress address

Most likely though you aren’t able to access your WordPress dashboard. So what you can do is override the settings above by inputting the values in your wp-config.php file.

The wp-config.php file is typically located at the root of your WordPress site and can be accessed via FTP, SSH, or WP-CLI. To hard-code WP_HOME and WP_SITEURL, simply input the following code towards the top of the file, changing the values to reflect your domain.

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

Below is an example of what your wp-config.php file might look like afterward.

change wordpress url wp-config.php
Change WordPress URL in wp-config.php file

Or if you prefer, here are two additional ways you could change your WordPress URLs without access to your admin dashboard:

  • Change WordPress URL Directly in Database
  • Change WordPress URL With WP-CLI

Once you manually set it, you can browse to your site to verify whether or not it fixes the redirect loop.

Multisite

If you’re changing domains on a multisite, make sure to also check the wp_blogs table. We’ve seen people do a search and replace wrong and cause an infinite redirect loop. This is because the network site doesn’t match the subsites.

wp_#_options: Each subsite will have sets of tables that correspond to the blog_id in the wp_blogs table. Go to the wp_#_options table, where # corresponds to the blog_id, and update the “SITEURL” and “HOME” settings in that table.

7. Temporarily Disable WordPress Plugins

When it comes to WordPress, temporarily disabling all your WordPress plugins can be a quick way to spot problems. For example, plugins such as Redirection or Yoast SEO premium let you implement redirects. Sometimes settings or updates to these plugins can conflict with redirects that might already be set on your server, causing a redirect loop.

Remember, you won’t lose any data if you simply disable a plugin. Most likely you can’t access the WordPress admin, so you’ll need login via SFTP to your server and rename your plugins folder to something like plugins_old. Then check your site again.

SFTP rename plugins folder

SFTP rename plugins folder

If it works, then you will need to test each plugin one by one. Rename your plugin folder back to “plugins” and then rename each plugin folder inside of if it, one by one, until you find it. You could also try to replicate this on a staging site first.

Rename plugin folder

Rename plugin folder

8. Check Redirects on Your Server

Besides HTTP to HTTPS redirects on your server, it can be good to check and make sure there aren’t any additional redirects setup wrong. For example, one bad 301 redirect back to itself could take down your site. Usually, these are found in your server’s config files.

Apache .htaccess file

Kinsta only uses Nginx, but if you’re using a WordPress host that is running Apache, it could very well be that your .htaccess file has a wrong rule in it. Follow the steps below to recreate a new one from scratch.

First, login to your site via FTP or SSH, and rename your .htaccess file to .htaccess_old. This ensures you have a backup.

Rename .htaccess file

Rename .htaccess file

Normally to recreate this file you can simply re-save your permalinks in WordPress. However, if you’re in the middle of an ERR_TOO_MANY_REDIRECTS error you most likely can’t access your WordPress admin, so this isn’t an option. Therefore you can create a new .htaccess file and input the following contents. Then upload it to your server. The following uses the default settings.

# 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

See the WordPress Codex for more examples, such as a default .htaccess file for multisite.

We’ve taken our knowledge of effective website management at scale, and turned it into an ebook and video course. Click to download The Guide to Managing 60+ WordPress Sites!

Nginx Config

If your host uses Nginx, this file can be a little trickier as the config file can vary a bit depending on the hosting provider. We recommend reaching out to your host and have them check your config file for anything that might be causing a redirect loop or too many redirects.

If you’re a Kinsta client, you’ll first want to check to ensure you didn’t set up a redirect wrong in our redirect tool. Below is a simple example of a redirect from https://domain.com/ back to itself, that would cause a redirect loop.

Bad 301 redirect

Bad 301 redirect

This also commonly happens when the location URL is included in both “Redirect From” and “Redirection To.”

For example, the following would cause a redirect loop:

Redirect From: ^/blog/about Redirect To: https://domain.com/blog/about-me

Why? Because once the process reached ^/blog/about, the remaining part -me wouldn’t matter, and it would cause an infinite loop. You have to specify the end of the string and the starter point. Here is what you would do to fix it:

Redirect From: ^/blog/about$ Redirect To: https://domain.com/blog/about-me

The $ character will tell Nginx to stop and match the request only if the string is there exactly, but nothing after it.

And of course, you can always open up a support ticket and we’ll check this for you.

Misconfigured Reverse Proxies

Another common reason for the ERR_TOO_MANY_REDIRECTS error is if you are using a reverse proxy. Reverse proxies can be quite complicated and it’s very easy to send your WordPress site into a redirect loop if misconfigured. Again, if you’re a Kinsta client, our support team can help with this.

Website stuck in an infinite redirection loop? 🛣 Check out these recommendations on how to get back up and running fast.Click to Tweet

Summary

Redirect loops can sometimes be tricky to track down. But hopefully, some of the troubleshooting steps above help you to resolve your ERR_TOO_MANY_REDIRECTS error. If we missed anything, feel free to let us know below in the comments.

Looks like no one’s replied in a while. To start the conversation again, simply

ask a new question.

Load cannot follow more than 20 redirections error on my iPhone 11

I keep getting this error message on my iPhone 11, I have cleared all the website data, and cleared history, but I continue to get this error message, it is only on my iPhone 11, and not on my iMac.

What else can I try?

iPhone 11,

iOS 14

Posted on Mar 5, 2021 6:42 PM

Similar questions

  • Too many redirects error
    I cannot access a specific website because safari indicated “too many redirections” error. This is on an iPhone 13 max but it also happened for the same website on an iPhone 10 max. I have only found instructions on what to do but it seems like it’s only for Mac laptops not iPhones

    185
    1

  • Iphone 6 Safari Browser issue.
    I am using iPhone 6 for 2 years and whenever I open my safari browser and try to open my website it shows an error and the website not loaded but I tried on other devices it’s working fine. Can you please tell me the solution that why Safari Browser is giving this error?

    Thanks

    [Link Edited by Moderator]

    111
    2

  • Cannot parse response
    Hi. I have visited this website before with no problems, and can sign in to it on my phone. Recently it now gives me an error message when I try to sign in.

    Cannot parse response (NSURLErrorDomain:-1017)

    Any ideas?

    202
    6

1 reply

Mar 8, 2021 10:00 AM in response to juoc

Hi there juoc,

Welcome to Apple Support Communities. We’re happy to help with this trouble you’re having with Safari on your iPhone 11. You can find the steps to help resolve this issue here:

If Safari displays a blank page or quits on your iPhone, iPad, or iPod touch

Let us know if this helps, and we can go from there if needed.

Best regards!

Load cannot follow more than 20 redirections error on my iPhone 11

Если вы видите ошибку Слишком много перенаправлений (ERR_TOO_MANY_REDIRECTS) в своем веб-браузере, значит что-то пошло не так. Также эта ошибка сопровождается сообщением Эта веб-страница имеет цикл перенаправления (This webpage has a redirect loop) и она блокирует загрузку сайта.

Ошибка Слишком много перенаправлений означает, что сайт продолжает циклично перенаправляться между разными адресами и это может никогда не прекратиться. Ваш браузер защищает вас от этого, разрешая только определенное количество перенаправлений (часто около десяти), прежде чем он «устанет» от этого и не выдаст данную ошибку.

Ошибка о цикличных перенаправлениях по-разному проявляется в разных браузерах:

Эта страница не работает (This page isn’t working)
{domain} перенаправил вас слишком много раз. ({domain} redirected you too many times.)
Или
Эта веб-страница имеет цикл перенаправления (This webpage has a redirect loop)
Попробуйте очистить ваши куки. (Try clearing your cookies.)
ERR_TOO_MANY_REDIRECTS

Google Chrome

Страница не перенаправляет должным образом (The page isn’t redirecting properly).
Произошла ошибка при подключении к {domain}. Эта проблема иногда может быть вызвана отключением или отказом принимать куки. (An error occured during a connection to {domain}. This problem can sometimes be caused by disabling or refusing to accept cookies.)

Mozilla Firefox

Safari не может открыть страницу (Safari Can’t Open the Page).
При попытке открыть {domain} произошло слишком много перенаправлений. Это может произойти, если вы открываете страницу, которая перенаправляется на другую страницу, которая затем перенаправляется на исходную страницу. (Too many redirects occurred trying to open {domain}. This might occur if you open a page that is redirected to open another page which is then redirected to open the original page.)

Safari

Очень часто это является результатом конфликтных перенаправлений, одно из которых пытается принудительно установить HTTPS (SSL) соединение, а другое – обратно HTTP (не-SSL), или между URL-адресами с www и без www.

Для таких CMS, ​​как WordPress или Magento, это решается приведением к общему конфигурации base_url или URL-адреса сайта в коде или базе данных с перенаправлением в файле .htaccess.

Как определить причину цикличного перенаправления

Вы можете следить за всеми перенаправлениями с помощью инструментов разработчика в браузере Firefox или Chrome. Эти инструменты обычно открываются нажатием клавиши F12 (или Ctrl+Shift+I). Откройте Сеть (Network), а затем перезагрузите страницу, на которой у вас возникла проблема.

После перезагрузки страницы вы увидите список перенаправлений. Проанализировав результаты, вы сможете найти «виновника» (если срабатывает перенаправление на одну и ту же страницу).

Основные типы перенаправления (код ответа состояния HTTP):

  • 301 редирект (постоянное перенаправление) – означает, что страница или элемент перемещен на постоянной основе, и браузер должен искать его в новом месте. Чаще всего записываются в файле .htaccess.
  • 302 перенаправление или редирект – это временное перенаправление, которое означает, что страница или элемент перемещен временно, и его адрес в будущем может измениться. Чаще всего записываются в коде веб-сайта.

Как исправить ошибку перенаправлений (редиректов)

Шаг №1: Очистить кэш и куки браузера

Очень часто циклические перенаправления могут вызываться файлами cookie в браузере, в которых закэшированы старые редиректы. Данные браузера, такие как история просмотров, кэш, файлы cookie и т.д., могут содержать ошибочные данные, которые вызывают ошибку ERR_TOO_MANY_REDIRECTS. Очистка этих данных – эффективный способ исправить ошибку. Чтобы очистить данные просмотра:

  • В Google Chrome нажмите Ctrl+Shift+Delete, выберите необходимые данные, время жизни данных и нажмите Очистить данные (clear data)
  • В Mozilla Firefox нажмите кнопку «Меню» и выберите «Параметры». Выберите Конфиденциальность, а затем очистить свою недавнюю историю (clear your recent history). Выберите Everything для диапазона времени, а затем нажмите Очистить сейчас (Clear Now).

После очистки данных браузера вы можете попробовать зайти на сайт и посмотреть, исчезла ли ошибка.

Шаг №2: Попробовать в других браузерах

Ошибка ERR_TOO_MANY_REDIRECTS может возникать только в браузере, который вы используете. Вы можете попробовать открыть тот же URL в другом браузере. Если ошибка не устраняется, значит проблема может возникать на стороне сервера.

Правильные настройки редиректов (перенаправлений)

Как мы уже упоминали выше, причиной ошибки могут быть неправильные настройки на вашем сайте. В основном, они касаются настроек редиректов в файле .htaccess. Данный файл – это файл конфигурации, который используется для изменения поведения сервера Apache для каждой папки на сайте или сервере. С его помощью можно редактировать только некоторые конфигурации Apache, хотя перенаправления обычно разрешается редактировать.

У вас может быть несколько файлов .htaccess, которые каскадно влияют на каталоги. Если у вас есть один .htaccess в родительском каталоге, и другой в подкаталоге, они оба будут влиять на этот подкаталог. Т.е., это может быть причиной конфликта между этими файлами на разных уровнях.

Ниже приведен ряд примеров перенаправления (редиректов) в файле .htaccess, которые обычно используются на сайтах.

Принудительный HTTPS

Приведенный ниже код сначала проверяет, поступил ли запрос на сервер с использованием HTTP или HTTPS. Если в запросе не использовался HTTPS, то конфигурация скажет браузеру перенаправить на HTTPS-версию того же веб-сайта и URL-адреса, которые были запрошены ранее:

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Принудительный HTTPS при использовании прокси-сервера

Вы можете использовать прокси-сервер, например, балансировщик нагрузки или веб-брандмауэр, для которого можно настроить использование SSL (HTTPS) на внешнем интерфейсе, но не на внутреннем. Чтобы это работало правильно, вам нужно проверять не только HTTPS в запросе, но и проверять, передал ли прокси-сервер исходный HTTPS-запрос на сервер, используя только HTTP. Код ниже проверяет, был ли запрос перенаправлен с HTTPS, и, если это так, не пытается дополнительно его перенаправлять:

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteCond %{HTTP:X-Forwarded-Proto} =http
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Перенаправление с HTTP на HTTPS в Nginx

Если на вашем веб-сервере работает Nginx, вы можете легко перенаправить весь ваш HTTP-трафик на HTTPS, добавив следующий код в файл конфигурации Nginx:

server {
 listen 80;
 server_name domain.com www.domain.com;
 return 301 https://domain.com$request_uri;
}

Замените domain.com на свой домен.

Принудительно без www

Следующий код в файле .htaccess проверяет, был ли запрошен сайт с www в начале доменного имени. Если www есть в URL, тогда он переписывает запрос и говорит браузеру перенаправить на доменное имя без www:

RewriteEngine On
RewriteCond %{HTTP_HOST} ^www. [NC] RewriteRule (.*) http://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Принудительно с www

Этот код в файле .htaccess проверяет, не было ли запрошено имя сайта с www в начале доменного имени. Если www не включен в URL, тогда он переписывает запрос и говорит браузеру перенаправить на www-версию домена:

RewriteEngine On
RewriteCond %{HTTP_HOST} !^www. [NC] RewriteRule (.*) http://www.%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Краткий итог

Если на вашем сайте есть редирект в файле .htaccess, что перенаправляет на URL, который не совпадает с тем, что находится в базе данных, вы можете получить ошибку в браузере о бесконечном цикле перенаправления (ERR_TOO_MANY_REDIRECTS), как описано выше.

Однако теперь вы знаете, как выглядят некоторые распространенные перенаправления в .htaccess. Также, с помощью данной статьи, вы сможете сами протестировать, найти причину ошибки, а также устранить ее самостоятельно.

Спасибо, что читаете нас!



  • 9562
  • Опубликовано 22/06/2019



  • Уроки программирования

0

WordPress site getting an issue on some devices. «Safari cannot open the page. The error was: ‘Load cannot follow more than 20 redirections.’»

Site works fine on some devices and some browsers but not others.

Any ideas on how to solve this for all visitors?

Thanks

  • wordpress
  • redirect
  • url-redirection

asked May 8, 2019 at 18:09

Will Simonds's user avatar

Will SimondsWill Simonds

11 bronze badge

1

  • Please provide some more context so we can help you with this. Perhaps some code or an example of it?

    May 8, 2019 at 18:17

Add a comment
 | 

Sorted by:

Reset to default

Your Answer

Sign up or log in

Sign up using Google

Sign up using Email and Password

Post as a guest

Name

Email

Required, but never shown

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged

  • wordpress
  • redirect
  • url-redirection

or ask your own question.

0

WordPress site getting an issue on some devices. «Safari cannot open the page. The error was: ‘Load cannot follow more than 20 redirections.’»

Site works fine on some devices and some browsers but not others.

Any ideas on how to solve this for all visitors?

Thanks

  • wordpress
  • redirect
  • url-redirection

asked May 8, 2019 at 18:09

Will Simonds's user avatar

Will SimondsWill Simonds

11 bronze badge

1

  • Please provide some more context so we can help you with this. Perhaps some code or an example of it?

    – Joey Phillips

    May 8, 2019 at 18:17

Add a comment
 | 

Sorted by:

Reset to default

Your Answer

Sign up or log in

Sign up using Facebook

Sign up using Email and Password

Post as a guest

Name

Email

Required, but never shown

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged

  • wordpress
  • redirect
  • url-redirection

or ask your own question.

[Решено] | ОШИБКА СЛИШКОМ МНОГО ПЕРЕАДРЕСАЦИЙ Быстро и легко

На чтение 4 мин. Просмотров 5.2k. Опубликовано 02.06.2021

20

Если вы видите « ERR_TOO_MANY_REDIRECTS » в своем веб-браузере, вы не одиноки. Об этом сообщили многие пользователи Windows. Эта ошибка возникает с сообщением « Эта веб-страница имеет цикл переадресации » и блокирует загрузку веб-сайта.

Почему возникла эта ошибка ?

Эта проблема обычно возникает, когда вы перенаправляетесь с исходного URL-адреса на новый, но, к сожалению, попадаете в бесконечный цикл перенаправления. Браузер обнаруживает эту ситуацию, прерывает цикл и отображает сообщение об ошибке. Причина, по которой вы застряли в этом цикле, может быть проблемой сервера или конечного пользователя.

Как исправить эту ошибку?

Вот четыре способа исправить эту ошибку цикла перенаправления ERR_TOO_MANY_REDIRECTS:

1) Протестируйте в других браузерах

2) Очистите данные вашего браузера

3) Проверьте расширения вашего браузера

4) Исправьте дату и время в системе.

Содержание

  1. 1) Протестируйте в других браузерах
  2. 2) Очистите данные вашего браузера
  3. 3) Проверьте расширения вашего браузера
  4. 4) Исправьте дату и время в вашей системе
  5. Вы также можете прочитать…

1) Протестируйте в других браузерах

Ошибка ERR_TOO_MANY_REDIRECTS может возникнуть из-за используемого вами веб-браузера. Вы можете попробовать посетить тот же URL в других браузерах . Если ошибка не устранена, проблема может исходить от сервера. Возможно, вам потребуется войти на сайт в другое время. Если ошибка не появляется в новом браузере, попробуйте следующие методы, чтобы исправить проблемы в исходном браузере.

2) Очистите данные вашего браузера

Данные браузера например, история просмотров, кеш, файлы cookie и т. д. могут содержать неисправные файлы, которые вызывают ошибку ERR_TOO_MANY_REDIRECTS. Очистка этих данных – эффективный способ исправить ошибку. Чтобы очистить данные просмотра :

В Google Chrome :

а) Введите « chrome://settings » в адресную строку и нажмите Enter , а затем нажмите Показать дополнительные настройки в внизу страницы настроек.

б) Нажмите Кнопка Очистить данные просмотра .

c) Нажмите Очистить данные просмотра .

И на Mozilla Firefox :

a) Нажмите кнопку Меню в Firefox, а затем выберите Параметры .

б) Выберите Конфиденциальность , а затем очистите вашу недавнюю историю .

c) Выберите Everything для Time диапазон, который нужно очистить, и затем нажмите Очистить сейчас .

После того, как данные браузера очищены, вы можете попробовать войти на веб-сайт и посмотреть, исчезла ли ошибка.

3) Проверьте расширения вашего браузера

Ошибка ERR_TOO_MANY_REDIRECTS может быть вызвана неправильное расширение браузера. Вы должны открыть диспетчер расширений в своем браузере, чтобы проверить расширения, которые вы установили в своем браузере.

Вот примеры проверки расширений в Chrome и Firefox.

a) Для Chrome введите « chrome ://extensions »в адресной строке и нажмите Enter . После этого вы увидите все перечисленные расширения. ниже, и вы можете попробовать включить или отключить любой из них.

b) Для Firefox введите « about: addons » в адресную строку, нажмите Введите , , а затем выберите Расширения . Вы увидите, что все расширения для Firefox перечислены здесь.

Вы можете отключить все расширения , чтобы проверить, решит ли это проблему. Если это так, вы можете активировать по одному расширению за раз , чтобы определить то, которое вызывает проблему.

4) Исправьте дату и время в вашей системе

Обычно ошибка ERR_TOO_MANY_REDIRECTS возникает из-за неправильных или устаревших настроек даты и времени в вашей системе. Чтобы исправить системную дату и время.

a) Нажмите клавиши Win + R на клавиатуре, чтобы вызвать окно «Выполнить». Введите « control » и нажмите Enter .

На панели управления выберите Дата и время .

c) Выберите вкладку Интернет-время и затем нажмите Изменить настройки .

г) В настройках времени в Интернете отметьте Синхронизировать с сервером времени в Интернете и выберите сервер времени . Затем нажмите Обновить сейчас и нажмите OK .

Дата и время в вашей системе теперь обновлены.

Вы также можете прочитать…

Как для подключения вашего компьютера к VPN.

Понравилась статья? Поделить с друзьями:
  • Ошибка too many different cell formats
  • Ошибка too few arguments to function
  • Ошибка tokyo ghoul re call to exist
  • Ошибка to run this application you must install net
  • Ошибка tns 12560 tns protocol adapter error