Free Hreflang Tag Generator
Add one row per language/region version of a page and get valid hreflang tags — every page in the set should carry the same tags, including a tag pointing to itself.
How to add hreflang tags to a multi-language site
-
1
Add a row per language version
Enter the hreflang code (e.g. en, en-US, fr) and the full URL of that version.
-
2
Add x-default if you have one
Point it at the page shown to visitors who don't match any listed language.
-
3
Copy the tags to every page
Paste the exact same set of tags into the <head> of each language version — including a tag pointing to itself.
Example use cases
Multi-language blogs & marketing sites
Serve the right language version of an article to visitors searching in that language.
Region-specific e-commerce pages
Point US, UK, and other regional storefronts at each other without being flagged as duplicate content.
Fixing missing or mismatched hreflang
Rebuild a clean, consistent tag set after finding gaps in an existing multi-language setup.
Frequently asked questions
What does hreflang do?
It tells search engines which language and, optionally, which region a page is written for, so they can serve the right version of a page to the right visitor in search results.
What language code format should I use?
An ISO 639-1 language code alone (e.g. en, fr, es), or a language plus an ISO 3166-1 region code separated by a hyphen (e.g. en-US, en-GB, pt-BR). Country codes alone, without a language, are not valid.
What is x-default for?
A catch-all entry for visitors whose language/region doesn't match any of the listed versions — typically pointed at your default or language-selector page.
Do I need a self-referencing tag?
Yes — Google's guidance is that each language version should include a hreflang tag pointing to itself, as well as to every other version, and this tool includes that automatically.
Where do these tags go?
Inside the <head> of every page in the set — the exact same set of hreflang tags should appear on each language version, not just the default one.