L’errore “Errore troppi reindirizzamenti” è un errore di WordPress che può essere causato da un plugin o da impostazioni errate. In effetti, è uno degli errori più comuni riscontrati dai nostri lettori e da altri utenti di WordPress.
Questo errore può persino bloccare l’accesso al sito web, rendendo la correzione un po’ complicata. Fortunatamente, abbiamo risolto il problema dei troppi reindirizzamenti più volte, quindi sappiamo esattamente cosa fare.
In questo articolo vi mostreremo come risolvere facilmente il problema “Errore di troppi reindirizzamenti” in WordPress. Inoltre, spiegheremo come ripristinare l’accesso al vostro sito web e come risolvere l’errore.
Suggerimento dell’esperto: Preferite lasciare la risoluzione dei problemi ai professionisti? I nostri servizi di assistenza WordPress sono in grado di correggere l’errore in pochissimo tempo e di far tornare il sito operativo. Inoltre, offriamo correzioni una tantum, così non dovrete preoccuparvi di contratti continui.
Cosa causa il problema “Errore di troppi reindirizzamenti” in WordPress?
L’errore “Troppi reindirizzamenti” è causato da un problema di reindirizzamento mal configurato in WordPress.
Come forse già sapete, WordPress dispone di una funzione di struttura degli URL SEO-friendly che utilizza la funzione di reindirizzamento. Allo stesso modo, molti popolari plugin di WordPress utilizzano questa funzione per impostare reindirizzamenti temporanei, creare reindirizzamenti 301 permanenti e correggere errori 404.
Se si utilizza un plugin per risolvere il problema del contenuto insicuro SSL o un plugin per la cache di WordPress, è possibile che influisca anche sui reindirizzamenti e causi l’errore “troppi reindirizzamenti”.
Ecco come appare il messaggio “ERR_TOO_MANY_REDIRECTS” in Google Chrome.
Tuttavia, questo errore non dice che cosa sta causando il conflitto e che sta forzando il ciclo di reindirizzamento in WordPress.
Ecco come si presenta l’errore in Firefox con il messaggio “La pagina non viene reindirizzata correttamente”.
Detto questo, vediamo come risolvere il problema dei troppi reindirizzamenti in WordPress.
Vi guideremo passo dopo passo nella risoluzione dei problemi, nell’accesso al vostro sito WordPress e nell’evitare che l’errore si ripeta.
Video tutorial
Se preferite le istruzioni scritte, continuate a leggere.
1. Cancellare i cookie e la cache del browser
Una causa comune dell’errore potrebbe essere rappresentata dai cookie del browser web. Provate ad accedere al sito web utilizzando un altro browser, come Firefox, Safari, Opera o Microsoft Edge.
Se si riesce ad accedere normalmente al sito web utilizzando un altro browser, è necessario cancellare i cookie del browser e la cache nel browser abituale.
Abbiamo una guida dettagliata su come cancellare la cache del browser in tutti i principali browser che vi aiuterà a farlo.
Se invece la modifica del browser non risolve il problema, si può passare alla fase successiva.
2. Disattivare tutti i plugin di WordPress
La causa più comune dei loop di reindirizzamento di WordPress o “ERR_TOO_MANY_REDIRECTS” è un conflitto di plugin. Un plugin di WordPress che tenta di impostare un reindirizzamento in modo tale da entrare in conflitto con i reindirizzamenti predefiniti di WordPress può causare questo messaggio di errore.
Per risolvere il problema, è necessario disattivare tutti i plugin di WordPress sul sito web. Normalmente, è sufficiente andare alla pagina Plugin ” Tutti i plugin nell’area di amministrazione di WordPress e disattivare i plugin da lì.
Tuttavia, supponiamo che a causa dell’errore di reindirizzamento non sia possibile accedere all’area di amministrazione di WordPress.
In questo caso, è necessario disattivare i plugin di WordPress utilizzando un client FTP come FileZilla o l’applicazione File Manager del pannello di controllo dell’hosting WordPress.
È sufficiente collegarsi al proprio sito web con un client FTP e accedere alla cartella /wp-content/
.
Qui troverete la cartella dei plugin
, che dovrete rinominare in ‘plugins.deactivate’.
In questo modo si disattivano tutti i plugin di WordPress sul sito.
In pratica, WordPress cerca una cartella chiamata plugins
per caricare i file dei plugin. Quando non trova la cartella, disattiva automaticamente i plugin attivi nel database.
Ora, potete provare a visitare il vostro sito web WordPress. Se ora siete in grado di accedere all’area di amministrazione di WordPress, significa che uno dei plugin ha causato l’errore.
Per capire quale sia il plugin colpevole, è necessario tornare al client FTP o all’applicazione File Manager e rinominare la cartella plugins.deactivate
in ‘plugins’.
Dopodiché, passate all’area di amministrazione di WordPress del vostro sito web e andate alla pagina Plugin ” Tutti i plugin. Da qui, potete attivare i vostri plugin uno per uno e poi visitare il vostro sito web per vedere se riuscite a riprodurre l’errore.
Una volta individuato il plugin che causa l’errore, è possibile trovare un’alternativa a tale plugin o segnalare il problema al forum di supporto WordPress del plugin.
3. Correggere gli URL di WordPress
Un’altra causa importante di questo errore è una configurazione errata delle impostazioni URL di WordPress. Normalmente, è possibile visualizzare queste opzioni nella pagina Impostazioni ” Generali “.
Per la maggior parte dei siti web, gli URL nei campi Indirizzo WordPress e Indirizzo sito devono essere uguali. Tuttavia, alcuni utenti possono ritrovarsi a utilizzare il suffisso “www” in un URL e un URL non www nell’altro.
Poiché potreste non avere accesso all’area di amministrazione di WordPress, potrebbe essere necessario correggere gli URL di WordPress utilizzando un client FTP o l’applicazione File Manager.
Collegatevi al vostro sito WordPress utilizzando un client FTP e andate a /wp-content/themes/your-theme-folder/
.
Da qui, è necessario trovare il file functions.php e modificarlo con un editor di testo semplice, come Notepad o TextEdit.
Successivamente, è necessario aggiungere il seguente codice in basso:
update_option( 'siteurl', 'https://example.com' );
update_option( 'home', 'https://example.com' );
Non dimenticate di sostituire “https://example.com” con gli URL del vostro sito. Ora è possibile salvare le modifiche e caricare il file sul proprio sito web.
Successivamente, provate a visitare il vostro sito web per vedere se l’errore si risolve.
Per ulteriori metodi, consultate il nostro tutorial su come modificare facilmente gli URL di WordPress.
4. Ripristinare il file .htaccess di WordPress
Il file .htaccess è un file speciale utilizzato dal server del sito web per gestire i reindirizzamenti e altre impostazioni del server. WordPress utilizza questo file anche per gli URL SEO-friendly e altri reindirizzamenti.
A volte, i plugin di WordPress possono apportare modifiche al file .htaccess del vostro sito web, innescando questo errore. È anche possibile che la disattivazione di un plugin non rimuova le modifiche dal file .htaccess.
In questo caso, è necessario reimpostare manualmente il file .htaccess di WordPress.
Anche in questo caso, dovrete accedere al vostro sito web utilizzando un client FTP o l’applicazione File Manager nel vostro cruscotto di hosting. Una volta collegati, vedrete il file .htaccess nella cartella principale del vostro sito web.
Nota: se non riuscite a trovare il vostro file .htaccess, consultate la nostra guida su come trovare il file .htaccess in WordPress.
Innanzitutto, è necessario scaricare una copia del file .htaccess sul computer come backup. Dopodiché, si può procedere all’eliminazione del file dal proprio sito web.
Ora potete provare a visitare il vostro blog WordPress. Se tutto funziona normalmente, significa che il file .htaccess ha causato l’errore di reindirizzamento.
Ora, poiché abbiamo cancellato il file .htaccess, è necessario ricrearlo. Normalmente, il vostro sito WordPress è in grado di farlo da solo. Per accertarsene, basta andare alla pagina Impostazioni ” Permalinks e fare clic sul pulsante “Salva modifiche” in basso.
5. Prevenire l’errore Troppi reindirizzamenti in WordPress
Speriamo che i passaggi appena descritti abbiano risolto il problema del reindirizzamento sul vostro sito web. Se il problema non è stato risolto, potrebbe essere necessario parlare con la società di hosting di WordPress per assicurarsi che non ci sia un problema di server.
Una volta risolto il problema sul vostro sito, dovreste essere in grado di capire cosa lo ha causato.
Se si tratta di un plugin, è necessario segnalare il problema al forum di supporto del plugin. Consultate la nostra guida su come richiedere il supporto di WordPress. Tuttavia, se non riuscite a ottenere aiuto, potete sempre trovare un plugin alternativo che faccia la stessa cosa.
Se l’errore è stato causato da un’errata configurazione del sito WordPress, è possibile prenderne nota e assicurarsi che le impostazioni del sito siano configurate correttamente.
Per ulteriori suggerimenti, consultate il nostro tutorial dettagliato su come risolvere i problemi di WordPress da soli come un vero professionista di WordPress.
Speriamo che questo articolo vi abbia aiutato a correggere l’errore “troppi reindirizzamenti” sul vostro sito web. Potreste anche voler mettere tra i preferiti il nostro manuale definitivo degli errori comuni di WordPress e vedere come contattare l’assistenza WordPress.
Se questo articolo vi è piaciuto, iscrivetevi al nostro canale YouTube per le esercitazioni video su WordPress. Potete trovarci anche su Twitter e Facebook.
Syed Balkhi
Hey WPBeginner readers,
Did you know you can win exciting prizes by commenting on WPBeginner?
Every month, our top blog commenters will win HUGE rewards, including premium WordPress plugin licenses and cash prizes.
You can get more details about the contest from here.
Start sharing your thoughts below to stand a chance to win!
Kamal
I tried all the solutions given above, still getting the same error “redirected you too many times.”.
It will be really helpful if I can get any SPOC from WordPress or any other solution which can be tried.
WPBeginner Support
If none of the methods from our article were able to solve the issue, we would recommend reaching out to your hosting provider to ensure nothing from their end could be the cause of the error and they should be able to help find the reason for the problem.
Admin
Kerri-Anne
If you’re using CloudFlare or something like that, especially with GoDaddy, that often causes a redirect loop as well. Update the DNS / Nameservers.
WPBeginner Support
Thank you for sharing what solved it for you!
Admin
Kingsley Chukwuemeka
In my case, the issue affects only some blog posts and I am wondering if this same process will work.
WPBeginner Support
It should still work even if it is only a few posts.
Admin
Valerie
Thank you, 3. Fix WordPress URLs – this one helped!
WPBeginner Support
Happy to hear our recommendation helped!
Admin
Nata
Thank you! Removing the plugin that caused the conflict helped.
WPBeginner Support
Glad our recommendations were helpful!
Admin
Mike
Thank you! Nothing was working for me, changing this SSL setting helped!
WPBeginner Support
Glad our guide could help!
Admin
Andrew
Thank you so much, deleting the ht.access file worked for me
WPBeginner Support
Glad our guide could help
Admin
Alex Froitzheim
Thanks so much for the article! In my case, the problem turned out to be a different one: My domain contained an umlaut (ü). I had to convert my domain name to Punycode and change my wordpress address and site address to the resulting URL.
WPBeginner Support
Thanks for sharing this for anyone who may also have this issue with an umlaut!
Admin
Brad Vickers
If none of the above works and you are using Cloudflare for DNS, check your SSL settings in Cloudflare. If you have an SSL installed on your hosting server, you need to change the SSL mode to Full (strict) in Cloudflare.
WPBeginner Support
Thanks for sharing what worked for you for this issue.
Admin
Jonathan Engelsma
This Cloudflare setting seems to have been my prob… after days of digging around. Thanks man!
Chethan Kumar
Thank you so much, it helped me a lot… My WP site is struck at page loading, i deleted .htaccess file from server after this working fine… you saved my time… loved it
Gimhan
Thanks a lot for the content. Removing the .htaccess file which I created manually and letting WordPress create the .htaccess file automatically resolved my issue.
Thanks again.
Mark Lidster
Man, you just saved me a whole heap of time as I’d created a url redirect from within the admin panel then couldn’t obviously get back in. Thought I was going to have to restore an old backup and lose all my work, but your simple addition to the config file via ftp saved all of that. Thank you so much
WPBeginner Support
Glad our guide was helpful
Admin
Stephen
Hi,
I tried to add the www. in general settings in wordpress as you suggested, only now i cannot acces my wordpress domain anymore… it says it does not recognize my login username and/or password, any suggestions?
WPBeginner Support
You can check your username and password using our guide below:
https://www.wpbeginner.com/beginners-guide/how-to-change-your-password-in-wordpress/
Admin
Solomon
Good day,
I have tried all these and nothing seems to be working.
WPBeginner Support
If none of these recommendations are working for you, we would recommend reaching out to your hosting provider for assistance
Admin
Jay Wulf
Hi, I was struggling with this issue for a while and it took me a great degree of research to actually find the solution.
If you are experiencing “Too many redirects” problem with Wordpress
In my situation, the new website was behind a reverse proxy (NGINX).
You need to add this to the fix list above.
Modify wp-config.php add the text
/**
* Handle SSL reverse proxy
*/
if ($_SERVER[‘HTTP_X_FORWARDED_PROTO’] == ‘https’)
$_SERVER[‘HTTPS’]=’on’;
if (isset($_SERVER[‘HTTP_X_FORWARDED_HOST’])) {
$_SERVER[‘HTTP_HOST’] = $_SERVER[‘HTTP_X_FORWARDED_HOST’];}
WPBeginner Support
Thank you for sharing for those on NGINX servers
Admin
Antoine
It solved my problem!
I was on HTTPS behind an nginx proxy and I had a redirect loop. Editing the wp-config did the trick!
Ian
Thank you so much, this fixed my problem on AWS (using Apache)
nechry
It also solve my redirect problem!
thank-you
Dhruv
Hello, my problem is not getting solved. My homepage is working fine but the wp-admin has this redirect problem
WPBeginner Support
You would want to go through some of our recommendations in our article below:
https://www.wpbeginner.com/beginners-guide/beginners-guide-to-troubleshooting-wordpress-errors-step-by-step/
To help find the issue
Admin
Jack Mwangi
I cannot be able to express my gratitude but I realy thank you very much for your assistance. The last method really worked for me.. Thanks a lot again.
WPBeginner Support
You’re welcome, glad our guide was helpful
Admin
Jim Biancolo
There’s a fix in the WP is_ssl() docs that worked for me
Mohammed Alshami
at my site i did all the mentioned steps and i still don’t get any thing i don’t know how to fix it anyone can help ?
WPBeginner Support
If none of our recommendations were able to assist, we would recommend reaching out to your hosting provider for them to take a look.
Admin
Jasmin Jai
Wonderful content and very informative! It took awhile but we were able to fix our WordPress issue online on our website because of your helpful article here! Thanks again.
WPBeginner Support
Glad our guide was helpful
Admin
Jim Biancolo
I was tearing my hair out over this and found another thing to check. If you’re behind a load balancer this can cause the Wordpress is_ssl() function to return incorrect values, which can put you into a redirect loop as it tries to redirect to a secure URL even though you’re already at a secure URL.
Mohammed Alshami
how did you fix it ?
Aylin
Hello. I have tried every recommendation that you have given: plugin, htaccess, wp-config.php but none of them works for me. Please help!!! Thanks
WPBeginner Support
If none of these recommendations were able to help you, then we would recommend reaching out to your hosting provider for them to take a look
Admin
Reginald
Thank you for this article. Very informative and the way you explained things was so helpful.
I understand the issue when it is happening over the entire website. My problem is that one category of pages (registration pages for my memberships) is being affected by this issue. Any idea why the error would be specific to a category?
Every other page on my site is working.
WPBeginner Support
You would first want to go through the steps in this article. If it still continues you would want to ensure you don’t have any plugins possibly creating redirects.
Admin
Joseph
Hi, Please what should i do?
i followed the steps involved in removing the /wp in my siteurl. then immediately i altered the wordpress and siteurl and saved changes, i have been unable to login into the wp-admin. the following is the error message i received.
“The document has moved here.
Additionally, a 302 Found error was encountered while trying to use an ErrorDocument to handle the request.”
thank you
WPBeginner Support
It would depend on which of the methods you used from our article below for removing Wordpress from your URL:
https://www.wpbeginner.com/wp-tutorials/how-to-get-rid-of-wordpress-from-your-wordpress-site-url/
Admin
Solomon Daniels
Hi! I cloned my site to a new URL using GoDaddy’s Installatron feature, and now when I try to access the cloned site using the new URL, it says ‘too many redirects.’ This means I can’t even access the Wordpress back end. Is there a way to try disabling plugins without that access? Do I just temporarily move them to a new folder? Or do you have any suggestions?
WPBeginner Support
We have a guide for how to disable plugins that you can follow here:
https://www.wpbeginner.com/plugins/how-to-deactivate-all-plugins-when-not-able-to-access-wp-admin/
Admin
Oksana
May God bless you, the author of this article!!!!
WPBeginner Support
Glad our article was helpful
Admin
U.A
Thanks a lot, solved a big issue for me here!
WPBeginner Support
You’re welcome, glad our article was helpful
Admin
ABDUL
That’s Why I Love wpbeginner, only one minute to solve. Thanx Syed balkhi sir And Team.
WPBeginner Support
Glad our guide was able to help you
Admin
Gofar ahmad
Thanks for all. I love wpbeginner. the best content.
WPBeginner Support
You’re welcome, glad you like our content
Admin
Mal
How did you know my service provider wouldnt take any blame….its like you new there feed back exactly
Thanks for saving the day
WPBeginner Support
You’re welcome, glad our article could help you solve the issue
Admin
Ben Jamir
Beautiful…so nicely explained..this solved my problem
Thank you for such a detailed post.
WPBeginner Support
You’re welcome, glad you found our post helpful
Admin
Daniel Cervantes
Well, our website was working just fine then all of a sudden our site went down,
I did all the steps above.
what else can we do?
WPBeginner Support
If the methods in this article aren’t working and you’re seeing the too many redirects error, you would want to reach out to your hosting provider to ensure this isn’t an error from their end.
Admin
Teja T. Diay
I tried with deleting the www. and now I can’t even log in in to the wp-admin anymore, I just get a page with info saying that my page is not working due to too many redirects.
How can I fix this, I need to continue developing my website.
“This page isn’t working redirected you too many times.
Try clearing your cookies.
ERR_TOO_MANY_REDIRECTS”
WPBeginner Support
You would want to bring back the www to your site, to do that you would edit the options table similar to our guide here:
https://www.wpbeginner.com/beginners-guide/how-to-reset-a-wordpress-password-from-phpmyadmin/
Once you do, for removing www you can follow our guide here:
https://www.wpbeginner.com/beginners-guide/www-vs-non-www-which-is-better-for-wordpress-seo/
Admin
Randy King
Here is a totally bizarre solution. The infinite login loop just started happening with no change in plugins, etc. I did everything – changed my theme, replaced the .htaccess file, etc. Here’s what I finally ended up doing that seems to have fixed everything: I rebooted my laptop and waited for several hours (in case it was a hosting problem). When I came back in, it all worked.
I tried clearing browser cache and did everything I could find, but nothing worked. I suspect there was something wacky going on that a reboot cleared up for me. And this is not the first time that this happened. Totally bizarre.
WPBeginner Support
That is an odd solution but thanks for sharing it, you may want to check with your hosting provider to see if they see the error as well if it continues.
Admin
SG
I’m facing a problem with my multisite network. Its created in local host. Everytime I try to access the new site it shows an error saying “The page isn’t redirecting properly”. If you can help that’d be great! Thanks
WPBeginner Support
You would want to start with the steps in this article to see if that resolves the issue
Admin
nasirey
i have problem for accessing my wordpress dashboard, when i try to access my wp- admin area it shows me your password is incorrect although my password is correct so if any one can help that kind of problem reply me. thanks.
WPBeginner Support
You could try force resetting your password using: https://www.wpbeginner.com/beginners-guide/how-to-reset-a-wordpress-password-from-phpmyadmin/
Admin
aleecode
awesome, it works. thanks
WPBeginner Support
Glad our recommendation could help
Admin
Lisa
Thanks for the article. I was able to fix my “too many redirects” problem by changing the http to https.
WPBeginner Support
Thanks for sharing the solution that worked for you
Admin
David Najman
Hi,
I had this error on the product tag page. I tried all the possible repairs mantioned above with no luck.
Finally, I had to rename slug for tags not to be numbers, eg. 2016, so I renamed it to r2016 and it started to work!
It must have been caused by some wordpress update, because it have been working few years before with tags named as numbers.
WPBeginner Support
Thanks for sharing what worked for you, if your product page is created by a plugin you may want to try reaching out to the plugin’s support to let them know about that issue
Admin
Yavan Kumar
Hi,
My whole website is running properly, but the homepage is redirected too many times and same issue with the wp-admin page too. I tried all the methods you mentioned but nothing worked for me.
Please advice me if there is any another solution for that.
Thanks in advance…
WPBeginner Support
If none of the methods from the article worked, you would want to reach out to your hosting provider for them to see if there are any issues they can see on their end.
Admin
John Zoetebier
My web site is a Bitnami Wordpress deployment on Google Cloud Platform.
When I use:
define(‘WP_SITEURL’, ‘http:/example.cloud’);
the home page gets redirected to itself and browsers error message.
I now use the original Bitnami setting and it works great !
define(‘WP_SITEURL’, ‘http://’ . $_SERVER[‘HTTP_HOST’] . ‘/’);
WPBeginner Support
You are missing a slash next to your http in the first define statement but thank you for sharing your workaround.
Admin
Chad
I had to desactivate a plugin and it worked back fine. I identified the plugin to desactivate by looking into my URL where I was getting a redirect error. The plugin name was written there.
WPBeginner Support
Thanks for sharing how you found the error for others trying to solve this problem
Admin
Nirav Patel
Thanks you bro for information of wp error
WPBeginner Support
Glad our article could help
Admin
irga
yeah, you know,,, i searching for it,,,,, and then mys wordpress site working again, thanksfull
Rahul
Thans buddy , really helps
Josh
I’ve tried all the steps here with no luck today. Luckily my website is functioning ok but I can’t log into the wp-admin dashboard for anything.
What are the other options? There must be other ways I can figure out what’s causing it?
Deby
I’m having the same. My site works fine for visitors, but I only get the redirect error for the backend, my WP dashboard.
It’s a new site and I don’t even have any plugins installed yet. I’m stumped.
Bryant Thomas
Holy Cow That worked, I’ve done many websites migrations and never ran into this issue. Thank you the define(‘WP_HOME’,’http://example.com’);
define(‘WP_SITEURL’,’http://example.com’); worked with the www.
Rutvi Trivedi
Hi, My problem is when I go to my site’s dashboard(/wp-admin) it is giving me this error I tried this solution and unfortunately it is not working. Please help me to solve this error.
Shakeane
I just want to say thank you so much for sharing this knowledge, you wouldn’t understand how much this has helped me, something as minor is adding www or leaving the forward slash at the end has caused so many headaches, thank you so much.
Marc
Awesome! Only took 5 minutes and fixed!!!