Build hreflang tags for multilingual or multi-region pages. Pick a language (and optional region), paste the URL of each version, and get clean HTML or sitemap XML output. Codes are validated against the ISO 639-1 (language) and ISO 3166-1 (region) standards.
One row per language/region version. The first row's checkbox marks it as x-default (fallback for unmatched users).
Pre-fill common multilingual setups.
Add a row and pick a language to see the output.
The hreflang attribute tells search engines that two or more pages are language or regional alternates of each other. When a user searches in a given language or country, the search engine can show them the matching version instead of the default page.
Each row represents one language or regional version of the page. One row per version (e.g., one for English, one for Spanish, one for Mexican Spanish). The "+ Add language version" button adds more rows; the trash icon on any row removes it.
The two-letter ISO 639-1 code for the page's language. Examples: en (English), es (Spanish), fr (French). Required for every row.
The two-letter ISO 3166-1 alpha-2 country code if this version targets a specific region. Examples: US, GB, MX, BR. Leave blank for a general language version (e.g., generic Spanish without a country).
The absolute URL of this language version. Must include https://. Each row needs a URL for the tag to be valid.
Marks this URL as the fallback for users whose language/region doesn't match any other version. Typically your English or international landing page. Only one row should be marked x-default.
One-click templates for common multilingual setups: English (US + UK), Spanish (Spain + Mexico), and a 5-language EU set. Each preset fills in the rows with example URLs you can edit.
HTML link tags = the format that goes in the <head> of every page in the group. Most common.
Sitemap XML = xhtml:link entries that go inside each <url> in a sitemap. Useful for many language versions or non-HTML pages.
HTTP Link header = the header format for PDFs and other non-HTML files. Only one of the three methods is used per page.
hreflang="LANG" or hreflang="LANG-REGION". LANG is a two-letter ISO 639-1 code (en, es, fr, de…). REGION is an optional two-letter ISO 3166-1 alpha-2 code (US, GB, MX, BR…). The special value x-default is the fallback shown when no other match is found.
Yes. Each language version should list all the others (including itself). This tool generates a single complete set that is identical for every page in the group.
Language codes are checked against the ISO 639-1 two-letter list (197 codes). Region codes are checked against the ISO 3166-1 alpha-2 list (249 codes). Codes that look right but aren't on the list are flagged in the validation panel.
If you are replacing an existing file (robots.txt, sitemap.xml, .htaccess, <head> tags, etc.), keep a copy of the original somewhere safe first.
No. Everything runs in your browser. Your URLs and language picks never leave your machine.