hreflang

hreflang Generator

Add each language or region and its URL, and get valid hreflang link tags — including x-default — ready to paste into your head. Generated in your browser.

1. Language versions

Local

2. Generated tags

HTML
About this tool

About hreflang Generator

The hreflang Generator builds valid hreflang link tags for each language or region you add, including the x-default tag, ready to paste into your head. It is for developers and SEO specialists managing multilingual or multi-regional sites.

Hand-writing hreflang is error-prone, and mistakes cause the wrong page to show in the wrong region. Generating the tags locally produces correct syntax with x-default handled, and your URLs stay private.

How to use

Step by step

  1. Add each language or region along with its page URL.
  2. Include an x-default entry for users who match no specific locale.
  3. Review the generated link tags.
  4. Copy them into the head of each corresponding page.
Key features

What it offers

  • Per-language and per-region hreflang tags
  • x-default support
  • Valid, ready-to-paste output
  • hreflang tags generated in the browser
Common use cases

Where it helps

  • Connecting language versions of the same page
  • Targeting regional variants such as en-GB and en-US
  • Adding an x-default fallback for unmatched visitors
  • Implementing hreflang during an internationalisation project
Best practices

Tips for best results

  • Make hreflang references reciprocal — every page in the set should point to all the others.
  • Use valid language and region codes, and point only to canonical URLs.
  • Include an x-default for visitors whose language or region you do not specifically target.
Common mistakes to avoid

Pitfalls to watch for

  • Listing a hreflang relationship on one page but not reciprocating it on the others; the references must be mutual.
  • Using an incorrect language or region code instead of the standard format.
  • Pointing hreflang at non-canonical or redirecting URLs.
Benefits

Why people use it

Correct syntax

Tags follow the expected hreflang format.

x-default handled

Covers visitors who match no listed locale.

Saves errors

Avoids the typos that break manual hreflang.

Private

Your URLs stay in the browser.

FAQ

Common questions

It tells search engines which language or regional version of a page to show users, helping international SEO and avoiding duplicate-content issues.
x-default marks the fallback page for users whose language or region does not match any of your specific versions.
A language code like en, or language-region like en-US. The tool validates the format and warns about likely mistakes.
No. The tags are generated entirely in your browser.
Private by design

This runs entirely in your browser

No file or text you enter here is uploaded. Encoding and decoding happen on your device using native browser APIs — close the tab and nothing remains on a server.

Install Toolisco Add it to your device for offline, one-tap access.