Hreflang
Commonly known as one of the most complex areas of technical SEO, hreflang tags are used to inform search engines of different country and language versions of a site. There are a lot of complex factors to consider to ensure the correct implementation of these tags and our SEO Office Hours notes cover many real-world scenarios and Google’s recommended course of action.
For more on international website optimization, check out our further resources:
The Ultimate Guide to International SEO
An SEO’s Guide to Hreflang Tags
The Challenges of Website Internationalization for Users & Search Engines
The Most Common Mistakes in International SEO
en-eu Hreflang Tags Aren’t Officially Supported Even Though They Can be Picked Up
Google has been able to pick up some instances of using the not officially supported ‘en-eu’ hreflang country code, but it isn’t used for anything. John doesn’t recommend using it.
Google Doesn’t Support Hreflang Links in Anchor Tags
Google doesn’t support hreflang links in anchor tags. John recommends implementing hreflang in the head of a page, in the HTTP header or in a sitemap file because it is complicated enough already without including it elsewhere on a page.
Hreflang Should be Between Pages of the Same Format
Hreflang links should be between the same formats of pages e.g. including hreflang links between AMP pages and separate mobile pages.
Hreflang Should be Included Between the Canonical Versions of Pages
Including hreflang on paginated pages is fine but the most important thing is to include hreflang tags between the canonical versions of the page.
Hreflang is Only Needed When the Wrong Language URLs Are Being Shown
If you don’t see the wrong country URLs appearing for users searching with a specific language, then it’s not necessary to add hreflang to those pages.
Google Can Understand International Sites Without Hreflang Guidance
Hreflang is best practice for international sites. However, Google can understand different language versions of a site without hreflang present through internal linking or the URLs themselves.
Hreflang Isn’t Needed for a Language Change
Hreflang is only needed for instances such as using the same language for different countries. It isn’t needed for a site which changes its language completely.
Large Hreflang Sets Should be Included in Sitemap Files
If you have a large set of hreflang tags then John recommends putting these in your sitemap files as this makes them easier to maintain.
Allow Users to Choose Different Language Sites Through Javascript Banners
John recommends using a Javascript banner which recognises the user’s location or settings and suggests a different language version of a page. This is ideal as it leaves the choice with the user, and also allows Googlebot to crawl other versions of the site without being forced to country sites through redirects.
Use X-default Hreflang Attribute for Default Versions of a Page
The x-default hreflang attribute should be used when you have a strong opinion about which version of a page is the default version, but it is not mandatory. X-default is also used on auto-redirecting homepages and language picker pages.