All tools

Hreflang Tags Generator

Build hreflang annotations for multilingual and regional pages.

One per line: a language(-region) code, a space, then the full URL.
Fallback for unmatched languages (optional).
Hreflang Tags

Generate Hreflang Tags

Hreflang annotations tell search engines which language and regional version of a page to show each user. They prevent duplicate-content problems across translations and make sure a French visitor lands on your French page, not the English one.

How it works

  • Each version lists every version, including itself
  • Codes use ISO 639-1 language + optional ISO 3166-1 region
  • x-default targets users no other version matches
  • Tags go in <head>, HTTP headers, or the sitemap

Common mistakes

Every hreflang set must be reciprocal — if page A points to B, B must point back to A. Use correct codes (en-gb, not en-uk) and always include a self-referencing tag, or search engines may ignore the whole set.

Where to place them

The tags generated here go in the <head> of each page. For large sites, hreflang is often easier to maintain in the XML sitemap instead. Whichever method you pick, apply it consistently — mixing methods can produce conflicting signals.

Private & Processed Locally

This generator runs entirely in your browser. Nothing you type is uploaded to a server, so it is safe for staging URLs, internal paths, and unreleased content, and it keeps working even when you are offline.

It is free to use with no sign-up and no limits — copy or download the output and drop it straight into your site.

Frequently Asked Questions

Common questions about the Hreflang Tags Generator.

What do hreflang tags do?
They tell search engines which language or regional version of a page to show each user, avoiding duplicate-content issues across translations.
What is x-default?
x-default is the fallback version shown to users whose language or region does not match any other version you have specified.
Do the tags need to be reciprocal?
Yes. Every language version must reference every other version, including itself, or search engines may ignore the set.

More SEO Tools

View all tools →
Meta Tag GeneratorRobots.txt GeneratorXML Sitemap GeneratorHTML Sitemap Generatorllms.txt GeneratorOpen Graph GeneratorTwitter Card Generator.htaccess Generator
File Transfer