Free SEO Tool

Hreflang & Canonical Tag Generator

Generate the full set of hreflang alternate tags for your multilingual pages — plus a clean canonical tag. Add each language and its URL, get a reciprocal block with x-default to paste into every page's <head>.

How it works, plainly: this is a rule-based generator, not an AI model. Every result is assembled from tested formulas, templates and validators that run entirely in your browser — no model call, no cost, and nothing you type is uploaded.

  • Free
  • No signup
  • Runs in your browser
  • Validates codes & URLs
Language code URL for that language
hreflang tags
 

How it works

  1. 01
    Add each language version

    Enter a language code (en, en-GB, de) and the URL for that version. Add a row per locale.

  2. 02
    Set an x-default

    Add a fallback URL for users whose language you don't target — recommended on every set.

  3. 03
    Get the reciprocal block

    We output one alternate tag per locale plus x-default — the same block goes in every listed page.

  4. 04
    Or generate a canonical

    Switch to the Canonical tab for a self-referencing canonical tag for a single URL.

FAQ

Frequently asked questions

What is an hreflang tag?
An hreflang tag tells Google which language and region a page is for, so it serves the right version to the right user. Each language version lists every version — including itself — with a <link rel="alternate" hreflang> tag, plus an x-default fallback.
Where do the hreflang tags go?
The same block goes in the <head> of every page in the set — each page must reference all the others and itself (reciprocal). You can also place them in your XML sitemap or an HTTP header; the head is the simplest, and that's what this tool builds.
What's the difference between canonical and hreflang?
Canonical picks the master URL among duplicates of the same content. Hreflang connects different-language versions of the same page. They work together: each language page is self-canonical and lists its hreflang alternates — don't point a canonical from one language to another.
What is x-default and do I need it?
x-default is the hreflang value for the page engines should fall back to when none of your listed languages matches the user — usually your language picker or your main-language page. It is optional but recommended: this generator adds it as a normal alternate link when you fill the x-default field, and warns you when you build a set without one.
Is it free and private?
Yes — no signup, no limits, and every tag is built in your browser. Your URLs are never uploaded.