I have a website that is in two languages, English and Dutch.

The URL structure is the following; domain is like mydomain.nl and and English page has URL mydomain.nl/en/pagename and Dutch has mydomain.nl/nl/pagename.

If main URL is visited without any language subdirectory appended, based on accept language header user is redirected to the "closest" match. In the menu a user can always switch the language of the current page.

In the Dutch Google, my site ranks relatively low (second page), I think because the search result in the Dutch Google seems to display the English result. That is, it has the English description and when viewed in cache, it indeed is the English homepage. This is unexpected, because a Dutch version is available and I would like the Dutch site/description being listed in the Dutch Google, and the English result for all other languages.

I use alternate language tags like this on the English version:

<link rel="alternate" hreflang="nl" href="http://www.mydomain.nl/nl/page" />

And on the Dutch version the opposite:

<link rel="alternate" hreflang="en" href="http://www.mydomain.nl/en/page" />

I also use this HTML tag <html lang="nl"> on the Dutch page and <html lang="en"> on the English page.

I'm not sure what else I can do to solve this problem. Any help is greatly appreciated.

  • Is the website hosted in the US and in your analytics where does the most common googlebot IP originate from? (U.S. ip?) It's possible the crawler is out of US data center with a "English" browser/crawler preference. This might be a partial cause of the reversed ranking issue
    – DMSJax
    Commented Dec 15, 2014 at 19:36
  • I'm the question asker (was posted on wrong account). Website is hosted in the Netherlands. Google Analytics does not really mention anything about bots. Awstats lists Google but no further information. Webalizer mentions: "Mozilla/5.0 (compatible; Googlebot/2.1; +google.co"
    – edwardmp
    Commented Dec 15, 2014 at 22:44

1 Answer 1


You may have multiple problems with this setup:

  • Googlebot doesn't send an "accept language" header. You need to handle this case somehow. One way would be to show a page that has links to both versions. Alternately, you could redirect to the default (probably Dutch) version.
  • Your redirects need to be 301 permanent. You may have implemented the redirects as 302 temporary redirects. This can cause Google to index the content under the wrong URL.
  • Because you are using a .nl domain, your content (even the English content) will only ever ranking in the Netherlands. If you want your content to rank in other countries, you need to to get a generic top level domain from Google's list of geotargetable domains.
  • Thanks for the answer. Yes I've read that bot does not send an accept language. I think it then redirects to the default (English at this point). But in the menu bar a link to the Dutch page is provided and vice versa. With the redirect you mean the redirect if no accept language was provided. Seems a 302 indeed. At this point thousands pages is both languages do actually show up in search, it's just that the root URL result is in English always (while the real root URL is not used, example.nl/lang/app is the main page). Domain extension change is not possible but scoring in NL is preferred.
    – edwardmp
    Commented Dec 15, 2014 at 22:48
  • Check the type of redirect on the root URL. If it isn't a 301 permanent redirect, make it so. That can be the cause of the content appearing to be indexed under the incorrect URL. Commented Dec 15, 2014 at 22:49
  • Yup it's a 301, confirmed using dnsqueries.com/en/googlebot_simulator.php. It was caused by a internationalization library in CodeIgniter. I changed it to a 302 redirect. So when mydomain.nl is visited, user is redirected to main page mydomain.nl/lang/app. Is that correct or would it be better to have main page really at the root domain? I also changed default language when no accept language is given to Dutch
    – edwardmp
    Commented Dec 15, 2014 at 23:07
  • It is supposed to be 301. Don't change it to a 302. Redirecting to a deep page from the root URL isn't bad other than making the URL complicated. Commented Dec 15, 2014 at 23:09
  • Oops I reversed it. It was a 302 and it's now a 301. I hope this and changing default language to Dutch helps. Thanks so much for you help! I can't accept the answer from this account, accidentally created that account and deleted it.
    – edwardmp
    Commented Dec 15, 2014 at 23:13

Your Answer

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