Sequence of 301 redirects

As far as I know, when I have /page1 and I do a 301 redirect to /page2, all the juice flows from /page1 to /page2, right?

Now I was wondering, would this also hold for the following:

/page1 -> /page2 -> /page3 -> /page4 -> /page5 -> /page6

(Where of course -> indicates a 301 redirect).

I will explain how I got to this absurd idea.
When I program websites is use these so called friendly URL’s.
An example URL for a sport webshop would be


www.mysportwebshop.com/products/1/t-shirts/men/longsleeve/with-print

Where 1 is the Id in the products table of my database.
Now, the client is filling the database with products, but he makes a lot of typos along the way, so the URL becomes


www.mysportwebshop.com/products/1/tshirts/man/longsleve/withprint

And now he’s going to correct these errors, but it might be google still knows the old URL.
I now want that when google goes to this URL, to 301 to the correct website, and I can check this all at once, or step by step, like so


www.mysportwebshop.com/products/1/tshirts/man/longsleve/withprint ->
www.mysportwebshop.com/products/1/t[B]-[/B]shirts/man/longsleve/withprint ->
www.mysportwebshop.com/products/1/t-shirts/m[B]e[/B]n/longsleve/withprint ->
www.mysportwebshop.com/products/1/t-shirts/m[B]e[/B]n/longsle[B]e[/B]ve/withprint ->
www.mysportwebshop.com/products/1/t-shirts/m[B]e[/B]n/longsle[B]e[/B]ve/with[B]-[/B]print

Of course rewriting the whole URL at once is much nicer and that’s what I’m doing right now. I was just wondering if these kind of “301 waterfalls” would do any harm.

I can’t say for sure either way, but I’d be worried about it. The spider has to have a redirection limit (max # it will follow) otherwise webmasters could tie up a googlebot process by infinitely generating redirects for it to follow.

Plus, our browsers have to follow these redirects too, and all major browsers definitely do have redirect limits after which they’ll stop and show an error.

Rather than using 301s for this, which would involve setting up every possible combination of misspellings, I think you’d be much better off using mod_rewrite to change each parameter on the fly. That will mean that each page will only get one redirect, because all of the changes will be made in one go, which will get around all the possible problems with a 743702041351801 (1). It will also make life much easier for you, because you’ll only need to add one rule for each correction to be made, rather than umpteen permutations and combintions. If nothing else, having that many 301s listed in your .htaccess file will increase server processor workload and thus page load time, not to mention the hours and days it will take you to write all the rules…

(1) That’s 301×301×301×301×301×301 :cool:

Thanks for you input, but as I’ve set it up now PHP is doing all the redirects. Since all information is coming from the database I know where to redirect to.
I was just wondering whether I could redirect one “atom” at a time, or redirect all “atoms” at once. Redirecting one “atom” at a time makes for -slightly- simpler code :slight_smile:

What you are describing is called “chained redirects” and while tolerated by the Search Engines, is frowned upon.

Especially Google who is one of the big SEs that looks at HTTP header response codes and the number/type of HTTP requests in each page call.

Redirects are a necessary evil (and a 302 is an unnecessary evil) of the interwebs, so should be avoided or mitigated against where possible.