Free international SEO utility

Hreflang Generator

Add each language or region version of a page. Generate reciprocal hreflang tags and XML sitemap entries for your alternate URLs.

Language versions

Use language or language-region codes such as en, ur, en-US or fr-CA. Include every alternate URL on each version of the page.

All values are processed in this browser. Check that alternate pages link back to the same language set.

How to use the Hreflang Generator

  1. Press Add language URL to create rows, then enter each version's language code (en, ur, en-US) and its full page URL.
  2. Add an optional x-default URL, then press Generate tags to build reciprocal alternate links and matching XML sitemap entries.
  3. Use the Copy HTML tags and Copy XML snippet buttons to paste the output into your page head or sitemap, or press Load sample to try it first.

Why it matters

For sites serving multiple languages or regions, hreflang is how you tell Google which page belongs to which audience. Without it, English, Urdu and Arabic versions can cannibalize each other, and users may land on a page they cannot read, raising bounce rates. Correct reciprocal tags with a valid x-default keep each audience on the right version, protect regional rankings and reduce duplicate-content confusion between near-identical translated pages.

Hreflang Generator FAQs

Do alternate pages need reciprocal hreflang links?

Yes. Each language version should carry the full set of alternate URLs, including a link to itself, so search engines can confirm the relationship. If one version omits a counterpart or links differ across versions, the hreflang signal weakens and Google may ignore it or serve the wrong regional page.

Does the tool check that my URLs are live?

No. It formats your entries locally and does not verify that the URLs exist, return a 200 status or are indexable. After copying the output, confirm every alternate page is live, canonicalizes to itself and points back to the same language set before the tags can work properly.

What is x-default and when should I use it?

x-default is a fallback hreflang value for visitors whose language is not covered by any of your targeted versions, typically pointing to a language selector or global page. The tool appends it alongside the alternates, but it is optional; sites that target a specific set of countries with no catch-all page can skip it.

Should hreflang go in HTML or the XML sitemap?

Google accepts both, and this tool generates both formats so you can choose. Inline head tags suit small sites, while the XML sitemap approach scales better for large multilingual sites with many pages. Whichever you pick, every language version must still reference the same complete set of alternates.