What is the Rel=”Alternate” Hreflang specification?
Google uses the Hreflang specification to understand and serve the best URLs for regional and language based queries.
This means that if you have websites or resources targeting specific languages or regions you can use the specification on your website to tell Google the best URLs to serve.
Let’s give a practical example: a British company that operates a sales operation and website in the UK, the United States, and in Germany.
This company wants its customers in each country to go to the correct website for their location – though it also wants all general English visitors to go to the UK website, and all German speakers to go to the German website.
You might use on-page markup in the following way on a resource:
<link rel="alternate" href="http://example.co.uk/" hreflang="en-gb" /> <link rel="alternate" href="http://example.com/" hreflang="en-us" /> <link rel="alternate" href="http://example.de/" hreflang="de-de" /> <link rel="alternate" href="http://example.co.uk/" hreflang="en" /> <link rel="alternate" href="http://example.de/" hreflang="de" />
Note that you should not include a country code on it’s own. Google will not automatically work out which language you are targeting if you specify a country, so always make sure to include a language.
Ways of Implementing Rel=”Alternate” Hreflang
There are three ways of implementing Rel=”Alternate” Hreflang:
Add the information in the <head> section of a webpage using link elements.
If implementing with on-page markup is problematic you can use a HTTP header instead.
Another alternative that may be useful for large websites is the ability to implement the Hreflang specification inside sitemaps.
How To Use Rel=”Alternate” Hreflang for UK Sites
The country code for the UK is GB – not UK. This is a common mistake websites make (be careful!).
If you were targetting the UK you would use en-gb which specifies English as a language and the UK as a region.
Does the Rel=”Alternate” Hreflang tag share link authority?
No, using the Hreflang specification does not share link authority. You can read more on this here.
Hreflang Language & Country Codes List
You can find an excellent list of language and country codes here.
Is Rel=”Alternate” Hreflang A Directive or a Signal?
Href is treated as a signal by Google not a directive, which means that if other factors indicate another URL would provide a better result Google may serve this page instead.
Need help with international SEO?
Find all this confusing? It is complicated stuff, but no problem. Get in touch and we can help out with your HrefLang tags or provide international SEO consultancy.