3

We use subdirectories on a global top level domain for a multi-regional site:

  • When a user from Iran enters www.exmple.com it 302 redirects to www.example.com/fa-IR.
  • When user enter from the US enters www.exmple.com, it 302 redirects to www.example.com/en-US.

In the URL section of our sitemap.xml we have something like:

<loc>http://www.example.com/</loc>
<xhtml:link rel="alternate" hreflang="fa-IR" href="http://www.example.com/fa-IR/" />
<xhtml:link rel="alternate" hreflang="en-US" href="http://www.example.com/en-US/" />
<xhtml:link rel="alternate" hreflang="x-default" href="http://www.example.com/fa-IR/" />

This pretty much how other large websites such as Microsoft's seem to work. Is the 302 redirect correct for SEO? Is our approach with the sitemap correct?

2

1 Answer 1

2

To be honest the answer is, it depends. Do you know how you are forcing a user to a particular country subdomain?

For example, Google Webmaster Trend Analysts recommend not redirecting users based on their IP --> https://www.seroundtable.com/google-dont-redirect-by-ip-location-24125.html. This is because Google's crawlers come from the US, which means, in theory, Google could only see the US subdomain.

When checking Microsofts site it seems that they are not 302 redirecting based on your location, from what I can see. It's just that the developers have chosen to use a global 302 redirect from the main .com/ root to the international directories e.g. /en-gb/, /en-nz/ etc. Which is not great from an SEO POV, it should be a 301 redirect.

However, the site does allow a user and bot to find other international sites using navigation links at the bottom left of the website in the footer. This allows users to navigate to a page (www.microsoft.com/en-us/locale.aspx) with different languages and regions. This is the best approach as it allows Google to crawl and index other international sites from links.

To summarise:

  • Identify if you're forcing users to an international subdomain based on IP
  • Make sure you have links so users and bots can navigate to international sites and don't force them back to an international site based on IP.

As for the second part of your question, I don't think you are using the hreflang="x-default" tag correctly in the XML Sitemap. Google states that this tag should be used for the following types of pages.

For language/country selectors or auto-redirecting homepages

Take as an example www.microsoft.com/en-us/locale.aspx would be used as the hreflang="x-default" tag. There is nothing wrong with using hreflang tags in your XML Sitemap you just need to make sure that they are setup correctly otherwise Google may ignore them if they are not configured properly.

I'd recommend taking another look at Google's help pages on the hreflang tag best practice --> https://support.google.com/webmasters/answer/189077?hl=en.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.