SEO Analysis Checker.com

Hreflang generator

Free hreflang tags generator

If you publish the same content in more than one language or for more than one country, hreflang is how you stop Google from showing the wrong version to the wrong person — or worse, treating your translations as duplicate content. Each hreflang annotation maps a language-region code to a URL, and done correctly it consolidates ranking signals across the cluster instead of splitting them.

This generator builds a complete, reciprocal set of <link rel="alternate"> tags from your locale and URL pairs. It normalizes each code to the correct casing (lowercase language, uppercase region), validates it against Intl.Locale, and flags the mistakes that quietly break hreflang in production: duplicate locales, relative URLs, missing x-default, and clusters with too few alternates to matter. Add a row per language version, copy the generated block, and paste the identical set into the head of every page in the cluster — including each page’s reference to itself. It all runs in your browser; nothing is uploaded.

Generator

Build a hreflang cluster

Every localized URL should list every alternate, including itself. Generate this same set for each page in the cluster.

Alternate 1
Alternate 2
Alternate 3

How it works

Fast, transparent, no signup

  1. Add a locale (e.g. en-US) and absolute URL for each language version.
  2. Add an x-default fallback for unmatched users, and keep locales unique.
  3. Copy the generated tags into the head of every page in the cluster, including a self-reference.

FAQ

Questions people ask about this tool

What are hreflang tags?

hreflang tags tell search engines which language and region a page targets, so Google can serve the right version to the right user. They look like <link rel="alternate" hreflang="en-US" href="..."> and belong in the head of every page in a translated cluster.

Do hreflang annotations need to be reciprocal?

Yes. If page A points to page B with hreflang, page B must point back to page A. Every page in the cluster should list every alternate — including a self-reference. This generator produces the full set so you can paste the same block on each localized page.

What is x-default for?

x-default marks the fallback URL for users whose language or region does not match any of your specified locales — often a language selector or your primary market. Google recommends including it in most clusters, and this tool warns you when it is missing.

What locale format should I use?

Use an ISO 639-1 language code, optionally followed by an ISO 3166-1 Alpha-2 region code: en, en-US, fr-FR, pt-BR. The region is uppercase, the language is lowercase. The validator flags codes that Intl.Locale does not recognize.