SEO ToolsAvailable now

hreflang Tag Generator

Generate hreflang link tags for multilingual and multi-regional websites to prevent duplicate content issues.

Language / URL entries
Generated tags (1)
<link rel="alternate" hreflang="en" href="https://example.com/page/" />

Paste these tags inside the <head> of every language version of the page. Each page should reference all other language variants, including itself.

About this tool

hreflang Tag Generator creates the complete set of <link rel="alternate" hreflang="..."> tags needed for multilingual or multi-regional websites. Proper hreflang implementation tells Google which language version of a page to show to users in each region — without it, Google may serve the wrong language version, split ranking signals across language variants, or flag pages as duplicate content. Enter the URL for each language/region variant, optionally set an x-default fallback, and the tool generates the full tag set ready to paste into your HTML head.

How to use

  1. Add a row for each language or region variant, selecting the language code and entering the full URL.
  2. Optionally enter an x-default URL (typically your homepage or language-selector page) for users whose language doesn't match any variant.
  3. Copy the generated tags and paste them into the <head> of every language version of the page.

Related Tools

FAQ

What is hreflang and when do I need it?

hreflang is an HTML attribute that tells search engines the language and optional geographic targeting of a page, and which other URLs are alternate language/region versions. You need it if you have the same (or very similar) content in multiple languages, or the same language targeting different countries (e.g. en-US vs en-GB). Without it, Google may treat your language variants as duplicate content.

What is the x-default hreflang value?

x-default marks the page that should be shown when no other hreflang value matches the user's browser language or location. It is typically your language-selector page, your most popular language version, or your homepage. It is not required but is recommended.

Do hreflang tags need to be on every language version of the page?

Yes — hreflang only works correctly when every language variant includes the full set of tags pointing to all other variants, including itself. If you add hreflang to the English version but not the French version, Google may ignore the annotations entirely.

Can I implement hreflang in a sitemap instead of HTML?

Yes. hreflang annotations can be added to an XML sitemap using the xhtml:link element, which is often easier to manage at scale. The HTML head implementation and sitemap implementation are equivalent — you only need one, not both.