Free hreflang Tag Generator

List each language version of a page and get the complete set of hreflang tags, as HTML head tags or XML sitemap entries, with an x-default fallback and basic validation of language codes and URLs.

Language versions of one page

Your hreflang tags

<link rel="alternate" hreflang="en" href="https://example.com/en/" />
<link rel="alternate" hreflang="hi" href="https://example.com/hi/" />
<link rel="alternate" hreflang="x-default" href="https://example.com/en/" />

Put the full set on every language version of the page, including itself. Missing return links are the most common hreflang error.

Common hreflang mistakes

  • No return link from the alternate page back to this one.
  • Underscores or made-up codes such as en_UK or english.
  • Alternate URLs that redirect or are blocked from crawling.
  • A canonical tag that points to a different language version.
  • Only translating body text and leaving titles and descriptions in the original language.

Multilingual SEO basics

  • Give each language its own URL, not a script that swaps text.
  • Translate titles, descriptions, headings and structured data.
  • Use real links for the language switcher.
  • List every language version in your sitemap.

Frequently asked questions

What is hreflang?

hreflang is an annotation that tells search engines which language or regional version of a page to show to which users. It helps the Gujarati page reach Gujarati searchers and the English page reach English ones, and reduces duplicate-content confusion between versions.

Where do I put hreflang tags?

In the head of each page, in the HTTP header for non-HTML files, or in your XML sitemap. Use one method consistently. This tool generates the HTML tags and the sitemap form.

Why must every page list all the alternates?

hreflang works only when versions point to each other. Each language page must list every version including itself, and the others must point back. Missing return links are the most common error and cause the tags to be ignored.

What is x-default?

x-default marks the page to show when no listed language matches the visitor, for example a language selector or your main English page.

Which language codes are valid?

Use ISO 639-1 language codes such as en, hi and gu, optionally with an ISO 3166-1 region such as en-gb or pt-br. Use hyphens, not underscores.

Ready to Transform Your Digital Presence?

Take the first step towards digital success with VeltrexLabs by your side. Our team of experts is eager to craft tailored solutions that drive growth for your business. Whether you need a stunning website, a powerful mobile app, or a data-driven marketing campaign, we've got you covered. Let's embark on this transformative journey together.

Unlock Your Digital Potential Today