How To Fix the Too many redirects error message

You might have come over this error:

AH00124: Request exceeded the limit of 10 internal redirects due to probable configuration error. Use 'LimitInternalRecursion' to increase the limit if necessary. Use 'LogLevel debug' to get a backtrace.

Or maybe noticed this in the browser:

Why this happens is because the site redirects you too many times. Usually this is by redirects happens in a loop. Meaning that you try to go to A, where A sends you to B but B sends you back to A again, and so forth.

This happens because somewhere in your code, files or settings there are more than one redirect commands that conflict with each other. A usual mistake is a redirect of, to But somewhere else it says the opposite, this will create a redirect loop. A https to http redirect loop is also common.

Control Panel

To fix it you can try to look in the control panel under settings

If you use both of them, make sure you use the same https domain.

.htaccess and wp-config.php

You can also check the .htaccess or wp-config.php file in your root/public/ directory.
Our default WordPress .htaccess file looks like this:

# 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]
# END WordPress

And in the wp-config.php file you can check if you have one or both of these statements set:



Check your base/home URLs in the database as well. Go to your control panel and under the database tab you can find a link to PhpMyAdmin.

The database log in credentials should be an email that get sent when creating a site/database.
Then navigate to the table where the base/home URLs is stored.

In WordPress this is stored at table wp_options, and under option_name you will find the value siteurl and home.

You can also use WP-CLI with SSH by running this command in the ~/public directory.

# For site URL
wp option get siteurl

# For home URL
wp option get home

Go through all of the steps above and see if any of them conflict with each other. Either remove all the redirects or make sure every one of them redirects to the same URL. Look closely for differences in http/https and www/ not-www URLs.

If you can’t fix it, contact us in the chat!

Give us your feedback on this article