
2026-12-02 · 7 min read
Hreflang explained, with a 7-language example
What hreflang does and doesn't do, a complete example for a site in 7 languages, the language and region codes, the three ways to add it, and the mistakes we find most often in audits.

If your website exists in more than one language, there is a good chance that some visitors land on the wrong version: the German page shows up for an Austrian search, the English one for someone typing in Polish, or two versions of the same page compete for the same results. Hreflang is the small piece of code that tells search engines which version is meant for whom.
It is also one of the most fragile parts of a multilingual site. One wrong code, one missing return link, and Google quietly ignores the whole set. This guide shows how it works through a full example in seven languages, and lists the mistakes we find most often when we audit international sites.
What hreflang does, and what it doesn't
It tells Google that several pages are versions of the same content for different languages or countries, so the search results can show the version that fits the searcher. The German speaker gets the German page, the Pole the Polish one.
It doesn't translate anything, doesn't make a page rank higher and doesn't merge the versions into one. Google treats it as a signal, not a command, and still decides the language of a page by reading its content.
That second point matters more than it seems. Hreflang only helps pages that already deserve to rank in their market. A Polish page that is a machine translation of the English one, built around keywords nobody in Poland searches for, will not be rescued by a correct tag.
The 7-language example
Take a currency exchange network with branches in several European countries. This is close to a setup we planned a search strategy for: Interchange FX needed one strategy for 10 countries and 7 languages. Suppose its "currency exchange at the airport" page exists in English, Italian, French, German, Polish, Czech and Hungarian. Every one of the seven pages carries the same block in its <head>:
<link rel="alternate" hreflang="en" href="https://example.com/en/airport-exchange/" />
<link rel="alternate" hreflang="it" href="https://example.com/it/cambio-aeroporto/" />
<link rel="alternate" hreflang="fr" href="https://example.com/fr/change-aeroport/" />
<link rel="alternate" hreflang="de" href="https://example.com/de/geldwechsel-flughafen/" />
<link rel="alternate" hreflang="pl" href="https://example.com/pl/kantor-lotnisko/" />
<link rel="alternate" hreflang="cs" href="https://example.com/cs/smenarna-letiste/" />
<link rel="alternate" hreflang="hu" href="https://example.com/hu/penzvalto-repuloter/" />
<link rel="alternate" hreflang="x-default" href="https://example.com/en/airport-exchange/" />
Five things make this set work:
- Every page lists every version, including itself
The Italian page names the Italian URL too. Google's documentation asks for this self-reference, and it keeps the set identical on all seven pages.
- The links go both ways
If the French page points to the Czech one, the Czech page must point back. Google ignores a pair where only one side confirms the relationship.
- The URLs are full and final
Absolute addresses with https and the domain, each returning a 200 status, not a redirect and not a page blocked by noindex.
- x-default catches everyone else
A Spanish or Dutch traveller has no version of their own, so they get the English page. Here the English page is both a language version and the fallback, which is allowed.
- The local URLs are localised too
"kantor-lotnisko" and "penzvalto-repuloter" are not decoration. They match what people in Poland and Hungary type, which helps the page long before hreflang comes into play.
The codes in this set are language codes, not country codes: "hu" stands for the Hungarian language, not for Hungary. That is why one "de" covers three countries here: German speakers in Germany, Austria and Switzerland all get the same German page. If the Austrian branches needed a page of their own, with their own rates and locations, the German set would split into "de-DE" and "de-AT", and "de-CH" if Switzerland got one too. A country code is only needed when the same language has more than one version.
Language and region codes
A two-letter ISO 639-1 code: en, de, pl, cs, hu. Use it when you have one version per language.
The language, a hyphen, then the ISO 3166-1 alpha-2 country code: de-AT, de-CH, en-GB. Use it when prices, delivery or offers differ by country.
The page for anyone who matches none of the listed versions. Often the English page, or a language selector.
The order is always language first. A country code can't stand alone: "at" means nothing to Google, and "en-UK" is wrong too, because the country code for the United Kingdom is GB. Other frequent slips are "cz" instead of "cs" for Czech and "jp" instead of "ja" for Japanese, where the country code was used in place of the language code.
Three ways to add hreflang
The link tags from the example above. The most common method and the easiest to check by viewing the source.
For files without an HTML head, such as PDFs. The same information is sent with the response from the server.
Each URL entry lists its alternates. Useful for very large sites, where the head would get long, but invisible on the page itself.
Google treats the three methods as equal. Choose one and use it consistently: two methods that say different things are a common source of conflicts.
The mistakes we find most often
- Missing return links
A new language version was added, but the older pages were never updated to point to it. The new page lists everyone, nobody lists it back.
- Wrong codes
en-UK, cz, a country used as a language, or an underscore (en_GB) instead of a hyphen.
- Hreflang pointing to the wrong page
Every language version points to the other language's home page instead of the matching page, so the set doesn't describe the same content.
- Canonical to another language
The German page has a canonical tag pointing to the English one. That tells Google the German page is a duplicate, and hreflang can't override it. Each version needs a canonical to itself.
- Links to redirects, 404s or noindex pages
Usually left behind after a relaunch or a URL change, when the tags were generated once and never updated.
- Automatic redirects by IP or browser language
The visitor, and Googlebot, are sent to "their" version before they can see the page they asked for. Google may then never see some language versions at all. A language switcher or a suggestion banner is the safer choice.
How to check your hreflang
Search Console no longer has a dedicated hreflang report, so checking is up to you. Crawlers such as Screaming Frog collect every hreflang tag on the site and flag missing return links, wrong codes and links to non-200 pages. For a quick look at one page, open the page source and search for "hreflang": the same set should appear on every version.
Our own site is a small example of the same rules. It has three languages and two kinds of pages:
The same page in three languages, with the same address in each language folder.
- en/en/services/seo
- hu/hu/services/seo
- de/de/services/seo
- x-default/en/services/seo
Written separately in each language, with its own address, linked because the topic is the same.
- en/en/seo/is-seo-worth-it
- hu/hu/seo/megeri-a-seo
- de/de/seo/lohnt-sich-seo
- x-default/en/seo/is-seo-worth-it
And this is what the head of the Hungarian article actually contains. The English and German pages carry exactly the same four lines:
<link rel="alternate" hreflang="en" href="https://seolins.com/en/seo/is-seo-worth-it" />
<link rel="alternate" hreflang="hu" href="https://seolins.com/hu/seo/megeri-a-seo" />
<link rel="alternate" hreflang="de" href="https://seolins.com/de/seo/lohnt-sich-seo" />
<link rel="alternate" hreflang="x-default" href="https://seolins.com/en/seo/is-seo-worth-it" />
Hreflang is the last step, not the first
A correct hreflang set is a technical detail that makes sure the right version shows up. Whether that version deserves to rank depends on everything before it: which markets to enter, what people search for in each language, and whether the page answers them better than the local competitors. That is the work behind international SEO, and it is why we never start a multilingual project with a translation brief.
When we audit an international site, the hreflang check is part of the technical analysis of every language version. We don't stop at a list of errors: we work out the fixes with your developers and check that the tags are correct on the live site. If the structure itself needs rethinking, for example country domains versus subfolders, see our domain structure service.
Not sure your language versions work?
Tell us which languages and countries your site covers and what you see in the results. We look at your language versions and your hreflang before we reply, and you get a proposal for an international SEO audit.
Tell us what you need — we'll send you a quote.






