Hreflang Tag Generator

Generate flawless hreflang link tags for every language version of your site — no syntax mistakes, no guesswork.

Hreflang tags tell Google which language and region each page version serves, so every visitor sees the right page. Add one row per version — a code like en or fr-CA plus its URL — and get the full set of link tags. Paste them into your page head.

Tip: add an x-default row pointing to your fallback page for visitors whose language matches none of your versions.

Your hreflang tags will appear here.
Advertisement

How to use the Hreflang Tag Generator

  1. Click Add Language Version for each translation of your page, then enter its language code (like en, ur, or fr-CA) and full URL.
  2. Optionally add an x-default row pointing to your fallback page for unmatched visitors.
  3. Click Generate Hreflang Tags and copy the link tags into the head of every language version.

Hreflang Tag Generator — FAQs

What is the correct hreflang format?

Use ISO 639-1 language codes like en, ur or ar, optionally followed by an ISO 3166-1 region code like en-US or fr-CA. Each tag looks like a link element with rel alternate, an hreflang attribute and the page URL. Every language version of a page must link to all the others, including itself — that is called being self-referencing.

What is x-default for?

The x-default hreflang value points to a fallback page shown to visitors whose language does not match any of your versions — often a language-selector page or your main homepage. It is not required, but Google recommends it because it gives crawlers a sensible default instead of guessing which version to show.

Do I need hreflang on every page or just the homepage?

Put the full set of hreflang tags on every translated page, not just the homepage. If your about page exists in English, Urdu and Arabic, each of those three URLs must carry tags pointing to all three. Incomplete sets are one of the most common hreflang mistakes and can make Google ignore the tags entirely.

Does this tool upload my URLs anywhere?

No. The generator runs fully in your browser — your language codes and page URLs are processed locally and never sent to any server or stored anywhere. The tags are assembled on your device the moment you click generate.

Related tools

Advertisement