
Everything you need to know about hreflang: what it is, how to implement it, how to check it, and the mistakes everyone makes. Now with notes on what has changed.
How to read this edition: then vs now
We first published this handbook in 2024. Rather than add a whole new layer of text, this edition keeps it short: sections that still hold up carry a green Still true in 2027 label, and anything that has changed gets one line in the form "In 2024 we said X, but in 2027 Y", with the source we checked. Want the full deep dive? It is all in Kira's International SEO Bootcamp on IMG Courses.
At a glance: what is still true in 2027
| Section | 2027 status | Note |
|---|---|---|
| What is hreflang? | Still true | Definition and lang vs hreflang unchanged. |
| When is hreflang used? | Still true | The three use cases still apply. |
| Regional language nuance | Still true | en-GB vs en-US targeting still works. |
| The importance of hreflang | Updated | History and duplicate content claims corrected. |
| What does this mean for your audience? | Updated | E-E-A-T is not a direct ranking factor. |
| Ways to implement hreflang | Updated | HTML, HTTP headers and sitemaps are equivalent. |
| Multiple domain names | Updated | Using several methods brings no extra benefit. |
| Geo-targeted redirects | Still true | Avoid automatic IP-based redirects. |
| Key domain considerations | Still true | Subfolder advice unchanged. |
| Building the hreflang attribute | Outdated | Generators and plugins replaced by AI connected to your CMS. |
| CMS plugins | Outdated | Shopify outputs hreflang itself; WordPress, Adobe Commerce and Strapi have MCP connectors. |
| How to check the presence of hreflang | Outdated | Checker tools replaced by an AI validation prompt. |
| Manual checking | Updated | Use rendered HTML or URL Inspection, not just view source. |
| Localisation tips | Updated | Still useful; Father's Day example corrected. |
| Example websites | Updated | Adidas removed; Swoop Funding and Jeep verified 4 Nov 2026. |
| Self-referential hreflang | Still true | Each page must list itself. |
| If the hreflang attribute is incorrect | Updated | Common errors still apply; use the AI prompt to check. |
| The x-default debate | Still true | x-default recommended, not compulsory. |
| Real-time hreflang | Updated | AI translation and connectors are here now. |
| Hreflang for e-commerce | Still true | Advice unchanged. |
| en-gb and en-us vs en | Updated | Google allows a language code on its own. |
| Canonical tags | Still true | Each version is its own canonical. |
What is hreflang?
Still true in 2027
Hreflang, or hypertext reference language, is an HTML attribute that is used to specify the language and regional targeting of a webpage. This helps search engines serve the correct version of a webpage to users based on their language and geographical location.
Here is the basic anatomy of an hreflang attribute:
<link rel="alternate" hreflang="en-US" href="https://diaryofanseo.com/us/" />
You have the language value, for example "en" for English, then the country value, for example "US", and the indexable URL, for example https://diaryofanseo.com/us/, which is the URL that is live and visible.
In our example, the page is in English, targets the United States, and lives at https://diaryofanseo.com/us/.
P.S. "Lang" is not the same as hreflang, so if you are just defining the language for your single variation website, that is not hreflang. The "lang" attribute is used to specify the language of the content within an element.
lang="en" is an HTML attribute used to declare the language of the content within a specific HTML element, such as a paragraph or an entire page.
Hreflang tags are used in the head section of your HTML to specify the language and regional targeting of alternate versions of a page for search engines.
You can also have structures that target the same country in multiple languages:
1.1 English in Spain, Spanish in Spain
<link rel="alternate" hreflang="en-ES" href="https://diaryofanseo.com/es/en/" />
<link rel="alternate" hreflang="es-ES" href="https://diaryofanseo.com/es/" />
1.2 English in Switzerland, Italian in Switzerland, French in Switzerland, German in Switzerland
<link rel="alternate" hreflang="en-CH" href="https://diaryofanseo.com/ch/en/" />
<link rel="alternate" hreflang="it-CH" href="https://diaryofanseo.com/ch/it/" />
<link rel="alternate" hreflang="fr-CH" href="https://diaryofanseo.com/ch/fr/" />
<link rel="alternate" hreflang="de-CH" href="https://diaryofanseo.com/ch/de/" />
It's worth noting that hreflang tags are signals and not directives, so they act as a recommendation to search engines on which page is most relevant for each location, and the search engine can choose other pages that it sees as more appropriate. There is also no requirement to have translated language pages; a lot of the time, when we refer to 'translated versions' of a webpage, we refer to regions rather than language.
There are a plethora of websites that target English speakers in multiple countries which have 'translated' pages that are all in English, but targeting countries like Hong Kong, Singapore, the United Kingdom, and Belgium, which would otherwise have different language versions, but they are for English speakers only.
Of course we can also have variations of language per country, which would look something like this:
<link rel="alternate" hreflang="en-GB" href="https://diaryofanseo.com/" />
<link rel="alternate" hreflang="fr-FR" href="https://diaryofanseo.com/fr/" />
<link rel="alternate" hreflang="es-ES" href="https://diaryofanseo.com/es/" />
We can assume that most French people in France would search in French, and most Spanish people in Spain would search in Spanish, so we now have our hreflang set up to specify to Google that we have a page for France, in the French language, a page for Great Britain (UK), in the English language, and a page for Spanish speakers within Spain.
When is hreflang used?
Still true in 2027
(1) When you have a fully translated site version
For a website with English and French versions targeting Canada:
<link rel="alternate" hreflang="en-CA" href="https://diaryofanseo.com/ca/en/" />
<link rel="alternate" hreflang="fr-CA" href="https://diaryofanseo.com/ca/fr/" />
(2) When you have different versions in the same language, targeting different countries
For a website with English versions targeting the UK and the US:
<link rel="alternate" hreflang="en-GB" href="https://diaryofanseo.com/" />
<link rel="alternate" hreflang="en-US" href="https://diaryofanseo.com/us/" />
<link rel="alternate" hreflang="x-default" href="https://diaryofanseo.com/" />
(3) When you have versions in different languages, targeting the same country
For a website with both English and Spanish versions targeting Mexico:
<link rel="alternate" hreflang="en-MX" href="https://diaryofanseo.com/mx/en/" />
<link rel="alternate" hreflang="es-MX" href="https://diaryofanseo.com/mx/" />
The difference between use case 1 and 3
Still true in 2027
In case (1) where there is a fully translated site version, different versions of the site are in different languages, but each language version targets the same country. For example, English and French versions of a site for Canada. This approach is used when you want to provide content in multiple languages for the same region, and is useful for multilingual countries like Canada, Singapore, Switzerland, etc.
In case (3) of "Different Versions in Different Languages, Targeting the Same Country", different languages are used for the same country, but the content may be tailored to different language speakers within that country. For example, providing both English and Spanish versions of a site for Mexico. This approach is used when the same region has multiple linguistic communities.
Case 1 is about offering fully translated content for a single country, while case 3 involves serving different languages to diverse language speakers in the same country, adapting to the cultural nuance of each language spoken.
Addressing regional language nuance with the hreflang attribute
Still true in 2027
It also addresses regional variations in language, like British English versus American English (this is actually super important!).
Hreflang is essential for multilingual websites, ensuring that users see the appropriate version of a page, whether it is a fully translated version, different versions in the same language targeting different countries, or different language versions targeting the same country.
For example, platforms like Reddit utilise hreflang to offer user-generated content (UGC) in multiple language options.
The importance of hreflang
Hreflang is the best thing since sliced bread. It allows us to show search engines what the relationship is between web pages in alternate languages.
This has been rather revolutionary for people looking to expand their websites globally, and helps increase the chances of accurately serving the appropriate language or regional version of a webpage to users based on their language preferences and location, reducing the risks of content duplication and improving user experience by presenting content that is tailored to people's linguistic and geographic preference.
If you have an English version for the UK and one for the US, the content will usually be very similar, with small differences in spelling (like colour and color). Hreflang is the invisible link that helps search engines understand that these pages are regional variations of one another.
2027 update
In 2024 we called duplicate content an SEO killer; in 2027 that isn't a risk here, as Google only treats localised versions as duplicates if the main content is left untranslated. Source: Google: localised versions
What does this mean for your audience?
Insight by Edward Ziubrzynski, Head of International SEO at Swoop Funding
Having effective hreflang implemented on your website allows you to serve content in either a native language, or targeted geo-location. This gives you the opportunity to better serve your customer base, with content that is solely relevant to them.
With targeted content, alongside acknowledgements of local authorities and governing bodies, such as GDPR in Europe and POPIA in South Africa, you show people that you understand their market. Making your content targeted, accessible, and in line with the market you are looking to compete in is essential for your strategy, and ultimately, your audience.
2027 update
In 2024 we listed five ways hreflang supports E-E-A-T; in 2027 that isn't relevant, as Google says E-E-A-T itself isn't a ranking factor. Source: Google: helpful content
Ways to implement the hreflang attribute
Still true in 2027
There are 3 ways to implement the hreflang attribute:
- In the HTML head section
- Through HTTP headers
- XML sitemap
Adding hreflang via the HTML head section
You can add your hreflang tags within the head tag of your web page. It is the most common method, but on larger websites it takes time and effort to keep the tags up to date, consistent and accurate.
The below website has opted for adding the hreflang tag via the HTML head section.

Implementing hreflang tags through the HTML section is fine for smaller websites, as it enables easier management and a unified point of reference, so you can see all your tags in one place and edit them whenever necessary. The choice of hreflang attribute implementation depends on the website.
2027 update
In 2024 we said this method slows crawling and indexing; in 2027 that isn't the case, as Google treats all three methods as equivalent. Keep the tags inside a well-formed <head>, and never combine hreflang with other attributes such as media in one link tag. Source: Google: localised versions
Hreflang through HTTP headers
Still true in 2027
Adding your hreflang through the HTTP header is a relevant method for non-HTML files, like PDFs, images or other downloadable content items where you can't directly modify the HTML structure to include tags for hreflang.
This is essentially so that your non-text content reaches the desired geographical location and audience and requires direct header manipulation as these files do not have a head section. The drawbacks of this method are that it is quite inconsistent, as not all search engines support this, so even if Google does, others may not, which will result in inconsistent results across search engines. It also isn't as flexible as the other options and is the most coding intensive out of all of them; it requires server-side configuration.
Here is an example of hreflang being implemented through the HTTP header:
HTTP/1.1 200 OK
Content-Type: application/pdf
Link: <https://diaryofanseo.com/guide.pdf>; rel="alternate"; hreflang="en-GB",
<https://diaryofanseo.com/us/guide.pdf>; rel="alternate"; hreflang="en-US",
<https://diaryofanseo.com/ie/guide.pdf>; rel="alternate"; hreflang="en-IE"
This method is not popular, especially considering that not all websites have necessary non-HTML content that absolutely must be visible in all the regions that the website is targeting, but it is good practice to know this exists and to make sure that any relevant non-HTML content is also regionalised to reach its intended audience.
Hreflang via XML sitemap
Implementing hreflang via the XML sitemap is an effective method for managing multilingual and multi-regional websites, especially when dealing with large sites or those with complex content structures. This approach helps centralise the hreflang annotations, making it easier to manage and update as opposed to embedding them directly in the HTML section of each page.
This method offers ease of updating, which means you can manage all of your hreflang annotations in one place, which is very useful for large websites with many pages. This method is also preferable for most e-commerce websites. It also offers dynamic content handling as XML sitemaps can be generated dynamically, allowing automatic updates as new pages are added or existing pages are modified.
The implementation method depends on the individual website, and should be analysed individually. Doing tailored research is required before settling on a preferred way to implement the hreflang attribute. At the end of the day it depends on how much skill and resource is available.
The thought process should be to choose an implementation method that is:
- Easiest to manage
- Will not incur too many errors
- Understood by managing team
- Helps reach global expansion goals
- Makes the global SEO project easier rather than more complex
- Will not impact website vitals (CDN, site speed etc)
This is what XML sitemap hreflang tag attributes look like:
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml">
<url>
<loc>https://diaryofanseo.com/us/</loc>
<xhtml:link rel="alternate" hreflang="en-GB" href="https://diaryofanseo.com/" />
<xhtml:link rel="alternate" hreflang="en-US" href="https://diaryofanseo.com/us/" />
<xhtml:link rel="alternate" hreflang="en-IE" href="https://diaryofanseo.com/ie/" />
<xhtml:link rel="alternate" hreflang="x-default" href="https://diaryofanseo.com/" />
</url>
<!-- repeat a
<url> entry for / and /ie/ with the same four links -->
</urlset>
2027 update
In 2024 we said sitemaps cut load times and speed up indexing; in 2027 that isn't relevant, as Google treats all three methods as equivalent. Yandex also no longer reads hreflang in sitemaps. Sources: Google: localised versions | Yandex: localised pages
Implementing hreflang across multiple domain names
Insight by Izzy Brand, Freelance International SEO Specialist
Although it is ideal for hreflang to be implemented on the same domain, there might be scenarios where this isn't possible, requiring an alternative setup:
- Company compliance: some clients may have company regulations or policies, requiring specific content to be hosted on local domains
- Local or TLD value: certain markets may place more trust in local domains or country-specific TLDs (top-level domains), making it more beneficial to use separate domains for different regions and language variations
- Resources: limited resources or technical challenges might make implementing hreflang on the same domain impractical and/or expensive, leading to the need for separate domains instead.
2027 update
In 2024 we recommended head tags plus a sitemap as a backup; in 2027 that isn't needed, as Google says using several methods brings no benefit. Cross-domain hreflang itself still works fine, so pick one method. Source: Google: localised versions
Geo-targeted redirect combined with language and region detection
Still true in 2027
There are many instances of websites that use the automatic redirection feature, which takes the user's IP and renders the most relevant content based on IP. This seems like a great idea in theory; however, it is full of SEO pitfalls. As Nick Jasuja, the founder of hreflang.org, says, "the road to hell is paved with good intentions" (Source: Redirection & International SEO, Nick Jasuja).
The main issue with this type of targeting is that when trying to access another regional part of the website, most of the time, the redirection will send the user straight back to the location of where the search was made, which can be inconvenient if the user is after a different version.
This can be confusing for both the human user and Googlebot.
When planning to implement automatic redirects, it is important to ensure that there is a separate URL that automatically redirects to a country/language selection page, rather than individual country-specific pages. An example would be a landing page where users can choose their preferred region and language.

It's best to never automatically redirect a visitor (whether human or bot) that is trying to access a specific language version page that has content.
In practice, this means never auto-redirecting when the page requested is one of the language versions.
A real life example of how this can be an issue is when Googlebot is crawling your website and mainly uses a United States IP, so the visit will be identified as a visit from a U.S. user.
When Googlebot tries to reach your French page, for example, it will get redirected to the English counterpart version. This makes Googlebot think that the French page isn't actually a separate page; instead, it views it as a duplicate that points to the English page, which will result in Google choosing not to index your French page and could display a "missing return tags" error.
This error occurs because Googlebot couldn't locate the correct French page that should be linked back to the English one.
Geo-redirects can be useful if they're implemented correctly; however, they do cause a lot of crawling and indexing errors, and also cause frustration when a user can't easily access a site selection which falls outside of their IP address. There are instances when this method works, especially when it is used in tandem with a comprehensive hreflang structure:


This pop-up is a convenient way for the user to choose the location that they prefer. Using GeoIP in conjunction with hreflang can be a good option to help direct users to the right pages and help Googlebot understand the structure of your international website.
Key domain considerations for setting up hreflang
Still true in 2027
Insight by Edward Ziubrzynski, Head of International SEO at Swoop Funding
When looking to establish a translated website, it is strongly recommended to apply this to your primary domain, instead of setting up country specific domains. This is to allow you to draw upon the authority your domain has built up over its existence, instead of starting fresh in each new target market you have.
For example: https://diaryofanseo.com/en-ca/ instead of https://diaryofanseo.ca/.
This means that any new page published in your country coded, translated subfolder will have a greater chance of being indexed and ranked by search engines, as you have historical authority and trust attributed to the domain, and thus, your new page.
This approach will allow you to enter new markets, or strengthen your position in existing markets at speed, and deliver content and traffic improvements at scale.
Building the hreflang attribute
2027 update
In 2024 we said to build tags by hand, with a generator or with a CMS plugin, but in 2027 we recommend letting an AI connected to your CMS build them, then checking the output.
Generator tool
2027 update
In 2024 we recommended Aleyda Solis's generator and Geotargetly, but in 2027 an AI connected to your CMS generates the full set for you. (Google still links to Aleyda's tool among third-party hreflang tools, noting it does not maintain them.) Source: Google: localised versions
Manually
2027 update
In 2024 we recommended generator tools and warned against writing tags with AI, but in 2027 we class those tools as outdated: an AI assistant connected to your CMS can build, implement and audit the whole set for you (see Hreflang in 2027 below). Always check the output. Sources: Google: localised versions
CMS plugins
2027 update
In 2024 we recommended hreflang plugins per platform, but in 2027 the platforms and AI connectors below do most of this work.
WordPress/WooCommerce
2027 update
In 2024 we recommended WPML, Weglot and Polylang for hreflang, but in 2027 they are best seen as translation tools. An AI assistant connected through WordPress's official MCP Adapter can now check and fix the hreflang they output. Sources: WordPress: MCP Adapter
Magento
2027 update
In 2024 we walked through Amasty and Mageworx menus, but in 2027 we class this manual setup as outdated: Adobe now offers official MCP servers so AI assistants can work with your Commerce store and code (see Hreflang in 2027 below). Sources: Adobe: Commerce development MCPs
Shopify
2027 update
In 2024 we showed hand-coded tags in theme.liquid, but in 2027 Shopify automatically includes hreflang tags through content_for_header, so the job is checking its output. If you do hand-code, use full https:// URLs. Sources: Shopify.dev | Google: localised versions
Strapi
The Internationalisation (i18n) plugin allows Strapi users to create, manage and distribute localised content in different languages, called "locales".
The i18n plugin offers users an admin panel to create multiple localised versions of their content and allows developers to build localised projects by fetching and consuming the right content depending on the country/language of the audience.
2027 update
In 2024 we said the i18n plugin does not translate content, but in 2027 Strapi has optional AI-powered translation and a built-in MCP server. Have a fluent person review auto-translated pages before publishing at scale. Sources: Strapi: Internationalization
How to check the presence of hreflang
2027 update
In 2024 we recommended the Hreflang Tag Checker Chrome extension, but in 2027 the quickest check is the AI prompt in the section 'If the hreflang attribute is incorrect' below.
Tools to check hreflang
2027 update
In 2024 we listed an online checker, Fetch & Render and Sitebulb, but in 2027 an AI connected to your site does this crawl for you (prompt below).
Manual checking
Still true in 2027
Although AI checks are generally reliable, sometimes websites have a very unique way of configuring their hreflang, they can also block certain public crawlers from accessing their websites, and some checkers may only read the hreflang that has been implemented via the HTML tags, in which case it is best to use the traditional ways to check if your hreflang is working.
Via source code CTRL + F
Go to the target website > Ctrl + F > search 'hreflang'
You should see something like this:

These may look different depending on the way that they were implemented; however, you should be able to see tags in one way or another.
In certain cases, companies opt for cross-domain hreflang, which is most visible when analysing it by looking at the tagging structure.
Sometimes, larger companies opt for GeoIP, or server side geotargeting redirection, or even a JavaScript hreflang embed, which might make hreflang discovery and validation slightly more difficult.
I have also found that sometimes, it's worth a manual validation even if you are using a tool for hreflang checks, as it may give you results that aren't accurate based on the live versions of these pages.
2027 update
In 2024 we relied on view-source checks, but in 2027 hreflang added with JavaScript only shows in the rendered HTML, and sitemap or HTTP header hreflang never shows in the source, so use Search Console's URL Inspection tool or ask your AI to read the rendered page. Source: Google: localised versions
Keyword search
At times, the most accurate way to assess hreflang implementation is on a page by page basis, by searching for the keyword or company name that has hreflang implementation in different countries to see if the correct result comes up in search.
Example: www.on.com
United Kingdom search (en-gb), English language search. Result: https://www.on.com/en-gb/

Germany search (de-de), German language search in Germany. Result: https://www.on.com/de-de/shop/classics/shoes

Switzerland search (it-ch), Italian language search in Switzerland. Result: https://www.on.com/it-ch/

All the above results render the correct pages that on.com was targeting, which means that they have succeeded in signalling the relevant pages per location in this particular instance.
2027 update
In 2024 we suggested checking results by switching Google country domains, but in 2027 Google redirects its country domains to google.com, so use a VPN or a rank tracker set to the country. Sources: Google: country code domains
Localisation tips for your international strategy
Insight by Raquel González Expósito, Freelance International SEO Consultant
Before launching your website in different languages or regions, you should follow these guidelines to ensure effective implementation of your localisation and hreflang strategy:
Research your target market
First, you need to understand your potential customers in each market you want to expand into. Consider that some countries have multiple official languages (like Switzerland), while some languages are spoken across various countries (like Spanish).
Based on your business type and target audience, you'll need to decide whether to create separate content for regions sharing the same language.
For example, if you're selling in both Spain and Mexico, evaluate if having a single Spanish version is sufficient, or if you need market-specific content.
This decision will directly impact your hreflang implementation: whether to use a general 'es' tag or specific tags like 'es-ES' and 'es-MX' for each country.
Prioritise the pages to localise
When expanding into various markets, you'll need to prioritise certain pages due to time, budget, or resource constraints. Remember that you only need to implement hreflang tags on pages that have localised alternatives. Focus on your most valuable pages first, like product, services, and key landing pages, and ensure their hreflang annotations correctly point to all available language/region variations.
Localise your keywords
When localising keywords, don't simply translate them directly. Instead, conduct local keyword research to discover the specific terms and phrases your target audience uses when searching for your products or services in their language.
Pay attention to local holidays and events, which might be celebrated on different dates. For example, Father's Day falls on the third Sunday in June in the UK and US, but on 19 March in Spain. Plan your content and promotions to align with these local celebrations to ensure relevance in each market.
Adapt currencies, measurements, and other regional standards
When deciding whether to separate content using specific hreflang country codes (like en-US and en-GB), also consider if you need to differentiate key regional elements. For instance, if you're selling products in the US and UK, you might need separate pages due to different currencies (USD vs GBP), measurement systems (imperial vs metric), payment preferences, or legal requirements.
However, if these elements don't significantly impact your content or user experience, a general language tag (like 'en') might be sufficient.
Monitor your performance in each market
Track key metrics and analyse user behaviour across different regions to measure the success of your localisation efforts.
If you have your localised versions in subfolders (example.com/es/) or subdomains (es.example.com), add each version as a separate property in Google Search Console. This will allow you to monitor each language or regional version's performance independently.
2027 update
In 2024 we got Father's Day wrong for the UK, now corrected above. Also, es-419 (Latin American Spanish) isn't supported by Google, so use plain es as the catch-all. Source: Google: localised versions
A few examples of websites with successful hreflang attribute implementation
Swoop Funding: https://swoopfunding.com/

Jeep: https://jeep.com/

2027 update
In 2024 we listed Swoop Funding, Adidas and Jeep, but in 2027 we have removed Adidas because we could not verify its tags. On 4 November 2026 Swoop Funding and Jeep still served hreflang, including x-default.
Self-referential hreflang attributes
Still true in 2027
Hreflang tags should include a self-referencing canonical URL, specify the page's own language version as a self-referencing hreflang tag, and reference all other international versions of the page.
In layman's terms, within the hreflang cluster, the page should reference itself as the canonical version, include itself within the hreflang variations of other regions, and include all its regional counterparts:
<!-- on https://diaryofanseo.com/us/shoes/ -->
<link rel="canonical" href="https://diaryofanseo.com/us/shoes/" />
<link rel="alternate" hreflang="en-US" href="https://diaryofanseo.com/us/shoes/" />
<link rel="alternate" hreflang="en-IE" href="https://diaryofanseo.com/ie/shoes/" />
<link rel="alternate" hreflang="en-GB" href="https://diaryofanseo.com/shoes/" />
If the hreflang attribute is incorrect
Still true in 2027
Hreflang implementation and building can go wrong very quickly, and a quick way to check this would be to ask an AI connected to your site to validate it, or conduct a manual check. Before your pages are indexed, you won't be able to see whether your implementation is correct or not. Ideally, test your hreflang in a staging environment before you send the website or site sections live, so you can troubleshoot in good time.
2027 update
In 2024 we recommended these checkers, but in 2027 an AI connected to your site can crawl and validate your hreflang for you. Copy and paste this prompt: Source: Google: localised versions
Copy this prompt
Fetch these pages and their hreflang alternates: [URLs]. For each page, check that: every alternate links back (return tags); language codes are valid ISO 639-1 and region codes valid ISO 3166-1 Alpha 2 (no UK, EU or es-419); each page lists itself; there is an x-default; the canonical is self-referencing and not pointing to another language or country version; every alternate URL is fully qualified with https:// and returns a 200 status. Report each problem with the page URL and the fix.
Then have a person spot-check a few key pages (your home page and top money pages in each market) to confirm what the AI reports.
Checking your hreflang implementation is imperative for a properly functioning hreflang structure. If there are errors either in your language and country codes, your attribute values, or your hreflang URLs referencing the wrong locations, this will harm the visibility of your international URLs, and crawling and indexing.
You may not explicitly know that your hreflang implementation is incorrect, but there will be signs. Here is an example from the Singapore Ministry of Foreign Affairs:

This is a Brazilian result, which is visible when searching for 'apply for singapore visa in uk'. This hreflang attribute is incorrect and will cause issues for the user, and will later impact the page itself considering how many users will bounce from this page (and is generally a frustration if someone is trying to apply for a visa to Singapore within the UK).
This is a huge inconvenience for e-commerce brands if you can only access an incorrect location, with incorrect currencies, shipping laws etc.

This is another example of hreflang errors: there are results showing for multiple countries at the same time, and one of the country and language values is completely incorrect (cn-en), as cn represents the country, not the language, and en represents the language, not the country. There is no country attribute "en"; the closest would be "gb".
Reverse placement of language and country codes
Still true in 2027
The anatomy of an hreflang tag needs to be followed accurately for it to function correctly, and an error that is quite prevalent is mixing up language codes with country codes. For instance, using CA-fr (French for Canada) when you mean fr-CA.
The correct format for hreflang is to specify the language code first followed by the country code if needed. The format should always be language-region (e.g., fr-CA).
Wrong country or language code used
There are often scenarios where either the country or language code isn't directly obvious. For example, using the Swiss country code may seem like it should be 'sw', but it is 'ch', as well as South Africa: it will not be 'sa', rather 'za'.
It's best to refer to the country and language code formats before trying to guess the language and country codes, as some of them are not as straightforward.
There are instances of language codes being used incorrectly, such as "eng-US". 'eng' does not exist; the correct language code is 'en', so 'en-US'. Longer codes do exist, though: for Chinese you can add an ISO 15924 script code, for example zh-Hans for Simplified and zh-Hant for Traditional Chinese:
<!-- script codes (ISO 15924) for Chinese -->
<link rel="alternate" hreflang="zh-Hans" href="https://diaryofanseo.com/zh-hans/" />
<link rel="alternate" hreflang="zh-Hant" href="https://diaryofanseo.com/zh-hant/" />
2027 update
In 2024 we called zh-Hans and zh-Hant language codes; they are script codes, which Google supports (for example zh-Hans-US). Use the standards Google names (ISO 639-1 for language, ISO 3166-1 Alpha 2 for region, ISO 15924 for script), and GB, not UK, for the United Kingdom. Source: Google: localised versions
Using continents or political regions for country codes
Still true in 2027
There are instances where political regions are used in place of countries, for example "en-eu" (English in the European Union) or "es-la" (Spanish for Latin America).
Political regions and continents are invalid region codes. EU stands for the European Union, which is a political region, not a specific country. The hreflang attribute requires the use of specific ISO 3166-1 alpha-2 country codes to specify language-region combinations correctly.
The x-default debate
Still true in 2027
Opinions on the importance of the x-default attribute are generally split. The x-default attribute is a special value for the hreflang attribute in HTML that signals to search engines which page to serve as the default when a user's language or regional preferences don't match any of the specified hreflang attributes.
It helps ensure that users are directed to the most appropriate version of a webpage when no direct match is found. Below is an example of x-default in action:
<link rel="alternate" hreflang="en" href="https://diaryofanseo.com/" />
<link rel="alternate" hreflang="de" href="https://diaryofanseo.com/de/" />
<link rel="alternate" hreflang="x-default" href="https://diaryofanseo.com/choose-language/" />
Is an x-default compulsory?
Still true in 2027
It's not 'compulsory', but it is recommended. If you're setting an x-default, all you are doing is letting search engines know that if someone searches for a result and there is nothing that is directly relevant, it outputs the most relevant fallback result.
X-default is preferred in most scenarios; however, it is relevant in a different sense for e-commerce brands.
If x-default is implemented for e-commerce, it's important to understand the reasons and the region behind the implementation. In this case, region agnostic x-defaults may not work as well.
If your x-default for India is the US, then the shipping information, pricing, and legal considerations are not relevant to India, so either Google will not show that page at all, or show a page that isn't relevant.
What is important, however, is to make sure that in the worst case scenario of your hreflang not showing the correct version, you at least show the version in the relevant language; to show a Spanish language page in Mexico, or a Chinese page in China.
In the case of e-commerce, automatic geotargeting (GeoIP) or manual country selection is a great option to go for if it isn't x-default.
Hreflang tag changes in real time based on proximity and relevant content language
2027 update
In 2024 we said AI might one day manage hreflang in real time; in 2027 it already does (see Hreflang in 2027 below), and Google says its AI features rely on the same core Search systems, so the same hreflang rules apply. Sources: Strapi | Google: AI features
Hreflang for e-commerce
Still true in 2027
Hreflang is an integral part of a successful international SEO strategy and helps businesses expand globally and target different demographics; this is true for all brands, not just e-commerce. Having an e-commerce website that targets the highest-search-volume countries for your products will attract millions of new visitors and help with global expansion. Brands like On, Adidas, Nike, Boohoo and many others have deployed an international SEO strategy and have successfully used hreflang to target multiple countries to sell their products.
Is there going to be a greater dilution by using en-gb and en-us instead of just using en?
No. Separate en-GB and en-US pages don't dilute each other: hreflang tells search engines they are one set of pages aimed at different regions. You can also use a language code on its own, such as en, as a catch-all for English speakers in countries you don't target separately.
2027 update
In 2024 we said to avoid plain en and rely on the lang attribute; in 2027 that isn't right, as Google allows a language code on its own and doesn't use the lang attribute to understand how pages relate. Source: Google: localised versions
Does the canonical tag need to be set to the main site or corresponding subfolder?
Still true in 2027
Each translated page will have a self-referencing canonical.
URL: example.com/au/shoes/
Canonical: example.com/au/shoes/
New in the 2027 edition
Recommended hreflang examples for 2027
A UK main site with US and Irish subfolders. Every page in the set carries the same lines, including one for itself, with full https:// URLs. Point x-default at a country selector if you have one, otherwise your main version. Sources: Google: localised versions
HTML (in the <head> of every version)
<link rel="alternate" hreflang="en-GB" href="https://diaryofanseo.com/" />
<link rel="alternate" hreflang="en-US" href="https://diaryofanseo.com/us/" />
<link rel="alternate" hreflang="en-IE" href="https://diaryofanseo.com/ie/" />
<link rel="alternate" hreflang="x-default" href="https://diaryofanseo.com/" />
Canonical alongside hreflang (on the US page): each version is its own canonical, in a separate link tag.
<link rel="canonical" href="https://diaryofanseo.com/us/" />
Several languages in one country (English and Irish for Ireland)
<link rel="alternate" hreflang="en-IE" href="https://diaryofanseo.com/ie/" />
<link rel="alternate" hreflang="ga-IE" href="https://diaryofanseo.com/ie/ga/" />
Hreflang in 2027: let AI do the manual work
Our view at DOAS: manual hreflang implementation is over. In 2024 we said building tags by hand was slow and that AI made too many errors, but in 2027 AI assistants such as Grok, connected to your CMS, can generate the full tag set, implement it and audit it for missing return links, wrong codes and canonical clashes. The human job is the strategy (which markets, which pages) and a final check. This is our opinion, not Google guidance; Google's rules on the tags themselves have not changed.
What the platforms officially offer (checked November 2026):
- WordPress: the official MCP Adapter plugin (on WordPress.org since October 2026) bridges the Abilities API, added in WordPress 6.9, so AI assistants can discover and run abilities that a site, theme or plugin exposes. Source
- Shopify: outputs hreflang automatically through content_for_header. Its official Dev MCP server (part of the Shopify AI Toolkit) lets AI coding assistants search Shopify's docs and validate Liquid and theme files. Source
- Magento (Adobe Commerce): Adobe offers an official Commerce MCP server (catalog, cart, pricing, checkout and more) and Commerce development MCPs for coding agents. We did not find an official MCP server for open-source Magento, so check any community server before using it. Source | Source
- Strapi: a built-in MCP server (Strapi 5.47.0 or later) lets AI clients create, read, update, delete, publish and unpublish content, limited by Admin token permissions. Source
None of these platforms documents a dedicated hreflang tool. The AI uses its general access to your content, theme or code, so give it the right permissions and review what it changes.
Other changes since 2024, in one line each
- In 2024 we pointed you to Search Console's International Targeting report, but Google deprecated it in 2022, so use a crawler and the URL Inspection tool instead. Source
- Google's canonical guidance: if you use hreflang, specify a canonical in the same language, and keep canonical and hreflang in separate link tags. Source
- Google's AI Overviews and AI Mode use the same core Search systems, with no extra technical requirements, so clean hreflang serves them too. Source
- Copilot searches through Bing, which has long favoured the content-language meta tag, so add it alongside hreflang. Source | Source
- Mass auto-translated pages with little value can fall under Google's scaled content abuse policy, so review priority pages with a fluent person. Source
- IndexNow can alert Bing, Yandex, Naver and Seznam to new language folders quickly; Google is not part of it, so keep using sitemaps. Source
The 2027 hreflang health check
If you only have fifteen minutes, run through this list for your top three markets:
- Every page in a set lists itself and all its alternates, with full https:// URLs.
- Codes are language first and ISO only: en-GB not en-UK, no EU, no es-419.
- Each country page has its own self-referencing canonical, in the same language.
- There is an x-default, ideally pointing to a country or language selector.
- No automatic redirects on localised pages; a suggestion banner instead.
- Bing gets a content-language meta tag; Yandex gets HTML hreflang, not sitemap-only.
- Auto-translated pages have been reviewed by a fluent person.
- You have checked AI Mode and ChatGPT answers in each market, not just rankings.
- You have run the AI validation prompt and spot-checked a few key pages by hand.
Closing thoughts: the bit that did not change
When we wrote the first edition, the big question was "which tag goes where?". Two years later the tags are almost exactly the same. What changed is everything around them: Google retired a report and its own country domains, a few old myths fell away, and a whole new set of answer engines arrived that do not always pick the right version the way Google does.
The lesson from this edition is that hreflang was never really about code. It is about respect for the person searching: their language, their currency, even their Father's Day. Search engines, old and new, keep getting better at spotting pages that genuinely serve a local reader, and stricter with pages that only pretend to.
We will keep this handbook evolving. Count how many of today's "Still true in 2027" labels survive the next edition, and for the full framework, see Kira's International SEO Bootcamp.
Credits
This guide has been created with personal knowledge and experience, as well as contributions and existing online resources. This guide uses expertise listed online by Kira Khoroshilova, Aleyda Solis, Backlinko, SISTRIX, Samuel Hurley, John Mueller, and Amsive Digital. The guide also includes expert commentary from Edward Ziubrzynski, Head of International SEO at Swoop Funding.
This guide will continue to evolve with new information based on the most recent SEO trends.



