Meta Tags Guide (Part 6): Hreflang, Language and International Pages
Implement hreflang and international metadata correctly: language-region targeting, canonicals, reciprocal links, x-default, sitemaps and debugging common mistakes.

International SEO becomes confusing when three different questions are treated as if they were one:
- What language is this document written in?
- Which URL should search engines treat as the representative version of this content?
- Which equivalent URL is intended for a user in another language or region?
Those jobs are handled by different signals.
The HTML lang attribute describes document language. Canonicalisation deals with duplicate or near-duplicate URL identity. hreflang connects alternate language or regional versions.
A reliable international implementation keeps those responsibilities separate and makes them agree.
Start with the page language
For an English page:
<html lang="en">
For French:
<html lang="fr">
For Brazilian Portuguese:
<html lang="pt-BR">
The lang attribute matters to browsers and accessibility technology. It helps software pronounce and process text appropriately.
Do not treat it as a magic geotargeting switch.
If a page is written in English but intended commercially for the UK, lang="en-GB" can accurately describe the linguistic variant, but your overall international architecture still needs appropriate URLs, content, internal links and alternate annotations.
What hreflang actually communicates
Suppose the same product is available at:
https://example.com/uk/product/
https://example.com/us/product/
https://example.com/fr/produit/
You can connect them:
<link rel="alternate" hreflang="en-GB" href="https://example.com/uk/product/">
<link rel="alternate" hreflang="en-US" href="https://example.com/us/product/">
<link rel="alternate" hreflang="fr-FR" href="https://example.com/fr/produit/">
Conceptually, you are saying:
These URLs are alternate versions of the same underlying page experience for different language/region audiences.
That is very different from saying one URL is canonical and the others should disappear.
Each alternate should normally identify itself too
A robust cluster includes the current URL in its own alternate set.
On the UK page, for example:
<link rel="alternate" hreflang="en-GB" href="https://example.com/uk/product/">
<link rel="alternate" hreflang="en-US" href="https://example.com/us/product/">
<link rel="alternate" hreflang="fr-FR" href="https://example.com/fr/produit/">
And equivalent annotations appear on the US and French pages.
This creates a reciprocal cluster rather than a collection of one-way declarations.
Reciprocal links are fundamental
If page A declares page B as an alternate but B does not point back into the same alternate relationship, you have an incomplete cluster.
This often happens when:
- one locale deploys independently;
- a CMS entry is missing a translation ID;
- one regional site has different templates;
- a newly launched locale is added to only some pages;
- an old URL redirects but remains in the alternate map.
Treat hreflang generation as structured site data, not as hand-written decoration.
Language and region codes are not arbitrary labels
The language component is based on language codes and an optional region can narrow the intended audience.
Examples:
en
en-GB
en-US
fr
fr-CA
de-DE
Do not invent values such as:
uk
eng-uk
english-gb
worldwide
GB is the region code for the United Kingdom; en is the language code for English.
Use region targeting only when it is meaningful
If the same English article genuinely serves every English-speaking user, this may be enough:
<link rel="alternate" hreflang="en" href="https://example.com/en/article/">
Creating en-GB, en-US, en-AU, en-IE and en-NZ variants that contain no meaningful regional differences can create needless operational complexity.
Regional URLs make more sense when pages differ in things such as:
- price or currency;
- shipping availability;
- legal terms;
- products;
- store locations;
- measurements;
- contact information;
- spelling/content that materially serves the market.
International architecture should follow the product and content reality, not manufacture regional pages merely to produce more URLs.
x-default is a fallback, not another country
You can designate a fallback URL:
<link rel="alternate" hreflang="x-default" href="https://example.com/product/">
This is useful for a generic selector, global page or fallback experience when no more specific language/region alternate is the best match.
Do not think of x-default as “international English”. It represents a fallback/default URL in the alternate set.
Canonical and hreflang must not fight
This is one of the most damaging implementation mistakes.
Imagine the UK page says:
<link rel="canonical" href="https://example.com/us/product/">
<link rel="alternate" hreflang="en-GB" href="https://example.com/uk/product/">
You are simultaneously saying:
- the US URL is the preferred representative;
- the UK URL is the UK alternate.
For genuine regional pages that you want independently eligible, the cleaner pattern is usually a self-referencing canonical on each locale:
<!-- UK page -->
<link rel="canonical" href="https://example.com/uk/product/">
<!-- US page -->
<link rel="canonical" href="https://example.com/us/product/">
and then a consistent hreflang cluster connecting them.
Google’s canonicalisation system can cluster similar regional pages, but your annotations should provide coherent signals rather than deliberately contradicting one another.
Same-language regional pages can be near duplicates
A UK and US page might differ only in price, shipping and a few words.
That is normal.
Google’s current canonicalisation documentation explicitly discusses regional variants and recommends using canonicalisation together with hreflang where appropriate so the search system can understand both duplicate relationships and regional alternatives.
The mistake is assuming that “duplicate content” automatically means one regional page must canonicalise to another and surrender its identity.
Three implementation methods
Google supports several ways of communicating alternate versions. In practice, sites commonly use HTML annotations or XML sitemaps.
HTML head
<link rel="alternate" hreflang="en-GB" href="https://example.com/uk/widget/">
<link rel="alternate" hreflang="en-US" href="https://example.com/us/widget/">
<link rel="alternate" hreflang="de-DE" href="https://example.com/de/widget/">
<link rel="alternate" hreflang="x-default" href="https://example.com/widget/">
This is easy to inspect but can become large on sites with many locales.
XML sitemap
Large international estates may find sitemap-based alternate management cleaner because locale relationships can be generated from a central content graph rather than injected into every page template.
The important thing is correctness, not choosing the method with the most markup.
HTTP headers
Headers can be useful for non-HTML resources in cases where alternate relationships need to be expressed without an HTML <head>.
Do not add multiple methods simply because you can. Every duplicate representation is another place for configuration drift.
Your URL architecture matters more than tiny tag tweaks
International SEO is much easier when locale identity is obvious and stable.
Common architectures include:
example.co.uk/product/
example.com/product/
or:
example.com/gb/product/
example.com/us/product/
or:
gb.example.com/product/
us.example.com/product/
There are trade-offs to each. What matters operationally is that your system can answer:
- what locale does this URL represent?
- what is its canonical URL?
- which content entity does it belong to?
- what alternate URLs exist for that entity?
- which alternates are live and indexable?
If your CMS cannot answer those questions, hreflang will eventually become unreliable.
Do not redirect users solely because of their IP
Aggressive geo-redirection can create terrible experiences and complicate crawling.
A UK user travelling in Spain may still want the UK site. A French-speaking user in Canada may want French content. A crawler’s apparent location is not the user’s preference.
Where possible, give users a visible locale choice and remember it rather than making every location decision irreversible.
Automatic suggestions can be useful. Forced, opaque redirection is much harder to operate safely.
Locale selectors should use real crawlable links
A language switcher should not depend entirely on JavaScript events that hide destination URLs.
Prefer normal links:
<a href="/gb/product/" lang="en-GB">United Kingdom</a>
<a href="/fr/produit/" lang="fr">France</a>
That helps both users and crawlers discover the relationship naturally.
Missing translations need an explicit policy
Suppose your English site has 10,000 pages but the German site has translated only 3,000.
Do not generate fictional German alternates pointing to:
- 404s;
- generic category pages;
- machine-generated placeholders;
- the German homepage.
If no equivalent page exists, omit that alternate for the content entity.
Hreflang should map equivalents, not merely prove that another locale exists somewhere on the domain.
Deleted and redirected pages must leave the cluster
International metadata often becomes stale after migrations.
If:
/de/produkt-old/
redirects to:
/de/produkt-new/
but every other locale still references the old URL, your cluster is carrying dead data.
Your deployment checks should verify that alternate URLs:
- return a successful indexable page;
- do not unexpectedly redirect;
- have the expected canonical;
- point back to the cluster;
- use the intended locale code.
The translated metadata should be translated too
A French page with a French body but an English title and English social description is unfinished localisation.
Localise the complete discovery surface:
<html lang="fr">
<title>Guide des en-têtes de sécurité HTTP</title>
<meta name="description" content="Configurez correctement les principaux en-têtes de sécurité HTTP.">
<meta property="og:title" content="Guide des en-têtes de sécurité HTTP">
Metadata is part of the user experience.
Do not let a translation workflow stop at the visible article body.
Do not use the old content-language meta tag as your architecture
Legacy snippets sometimes include:
<meta http-equiv="content-language" content="en-GB">
Modern HTML has a direct language mechanism:
<html lang="en-GB">
Use current semantic HTML rather than accumulating obsolete-looking metadata because an old SEO checklist told you to.
JavaScript frameworks: generate locale metadata at render time
International sites built with SPAs or hybrid frameworks often have route-aware metadata APIs.
Use them so the initial document for:
/fr/guides/security/
already contains the French title, description, canonical and alternate relationships.
Do not ship one generic English <head> and rely on client hydration to transform it later.
The same principle applies to canonical and robots metadata: the initial public response should communicate the intended page state cleanly.
Testing hreflang programmatically
For a large site, manual spot checks are not enough.
For every locale cluster, a crawler can validate:
URL is reachable
canonical is expected
page is indexable
self hreflang exists
all expected alternates exist
alternate codes are valid
all alternate URLs are reachable
relationships are reciprocal
x-default is consistent where used
This turns international SEO from a mysterious Search Console problem into a testable data-integrity problem.
Think in content IDs, not URL strings
A strong CMS model might look conceptually like:
{
"contentId": "product-1234",
"locales": {
"en-GB": "/gb/products/widget/",
"en-US": "/us/products/widget/",
"fr-FR": "/fr/produits/widget/"
}
}
The renderer can then generate alternate annotations from one authoritative relationship.
That is far safer than editors manually pasting URLs into eleven locale records.
Check the page before blaming hreflang
A SiteTidy audit can surface canonical, indexing and metadata problems that often sit underneath international-search issues.
International-page checklist
For each locale page, verify:
<html lang>describes the page language;- the URL represents the intended locale consistently;
- the page has a sensible self-canonical when it should remain independently eligible;
- alternate annotations use valid language/region values;
- the current page appears in its own alternate set;
- alternate relationships are reciprocal;
x-defaultis used deliberately rather than as a mystery catch-all;- alternates return live pages rather than redirects or errors;
- metadata is actually translated/localised;
- locale links are crawlable and usable;
- geo-routing does not trap users;
- missing translations are omitted rather than mapped to irrelevant pages;
- sitemap and HTML implementations do not contradict one another;
- migrations update the whole locale cluster.
The principle to remember
International metadata works best when it describes a real, well-modelled content relationship.
If the underlying site knows which pages are equivalent, which locale each URL serves and which version is canonical, generating correct annotations is straightforward.
If the underlying site does not know those things, adding more hreflang tags will not solve the architecture. It will merely encode the confusion.
