Redirection and International SEO

Many websites try to make the user’s life easier by automatically redirecting her to the language/region version of their content that they infer based on IP address. But this approach is full of SEO pitfalls you should know about. In other words, the road to hell is paved with good intentions.

If you do automatic redirects, make sure there is a separate page (URL) that redirects to the appropriate page. No individual country/language URL should auto-redirect. In other words, do this:

The right way to use auto-redirection with Hreflang for international SEO.

The 3 language versions are self-explanatory. But note that the x-default version of the page is a new URL, different from all the others. Only visitors to that specific URL should be automatically redirected. Based on their IP address, you can choose to redirect them to any of the 3 language-specific pages.

However, if a visitor from Ireland is trying to access your /fr/ (French) page, let her access it. Do not redirect her to English. Not only can this be frustrating for someone genuinely interested in the French page, it can also lead to all kinds of trouble with search engine bots.

Say Googlebot is crawling your site. Google tends to use a 66.249.x.x IP address, which is a U.S.-based IP. So your smart website will detect a US visitor. Now when Googlebot tries to access the French page, it will get redirected to your English page. So Googlebot will think the French page isn’t really an independent page after all; it’s just a duplicate that redirects to the English page. Google will be forced to ignore your French page, and might show you a “missing return tags” error because it couldn’t find the right French page that links back to the English page.

Mistakes to Avoid when Auto-redirecting
I prefer language/country chooser pages rather than automatic redirects because redirects are easy to screw up. But if you absolutely must use redirects, here is how to do it:

  • Use separate redirector pages solely for redirecting. Use 1 redirector page for each set of internationalized pages. In the example above, http://www.example.com/product is the redirector page for the set of 3 pages http://www.example.com/en/product.html, /fr/product.html and /es/product.html. Similarly, you can have /product-2 auto-redirect to one of /en/product-2, /es/product-2 and /fr/product-2.
  • Never automatically redirect a visitor (human or bot) that is trying to access a specific language version page that has content. In our example, that means never auto-redirecting when the page requested is one of http://www.example.com/en/product.html, /fr/product.html or /es/product.html

Using Cookies:
When you use an IP address to auto-redirect, the process involves a potentially time-consuming or expensive step of geolocation. Many websites store a cookie on the user’s browser to cache info about the user’s detected locale; this is done so that for all subsequent page requests, the geolocation step can be skipped. It makes the website faster, but when it’s done wrong it can create problems. It is infuriating as a user to find that a website will not let you change your locale even if you want to. Say a Spanish user is traveling and in London right now. Based on their IP address, they were auto-redirected to /en/page.html instead of what they wanted i.e., /es/page.html. Not only were they redirected, they were cookied — let’s label this an English user because we know they want English! Except they don’t. Don’t make the user’s life difficult by cookie-ing them and removing all options to change their language.

Cookies are also used when there is a country-chooser page where a user manually selects their preferred language. The cookie is meant to save the user’s choice but sometimes creates problems. For example, airline websites for international travelers may save the user’s choice of a foreign country and not let them choose their home country even after they return home.

If you get technical SEO on your site right, you won’t need cookies. Say the user goes to www.airlinewebsite.com and chooses US/English as her site content preference. She is redirected to the US/English site. Ideally, all links on this version of the site should point to the US/English version of the content they are linking to. e.g. /en/product.html should link to /en/product2.html, /en/shipping.html etc. Once the user is in the English bubble, ordinary browsing will naturally and effortlessly keep her in the English bubble. Use country-chooser pages to let the user change this preference freely, without using cookies to force them into this bubble.

Here’s to saner international SEO!

Published by

Nick Jasuja

Nick Jasuja is the founder of Hreflang.org and Diffen, the world's largest collection of unbiased comparisons. Diffen's expansion to Spanish was Nick's first foray into international SEO and motivated him to launch the Hreflang testing tool. You can find him on Twitter @thisislobo.