Hreflang generator
Enter language code and URL on each line
Hreflang generator
What is hreflang?
Hreflang identifies equivalent pages in different languages or regions. It helps search engines select an appropriate version for a visitor, rather than translating the page itself.
How to use the generator
Enter one language code and absolute URL per line. Include the current page and use the same set of links on every equivalent page. Use x-default for a suitable fallback when needed.
Practical example
An English product page and its Lithuanian translation can use en and lt. A regional English page may use en-GB. Each page should reference itself and the other equivalent pages.
Should I use canonical and hreflang together?
Normally each indexable translation has its own canonical URL. Avoid pointing every translation to the English page. Check that the alternate URLs are accessible and return reciprocal links.
Does the tool check live pages?
No. It generates markup from your input. Check HTTP responses, canonical tags and reciprocal links after publishing.
What it does
Generate alternate language links for equivalent localized pages.
How to use
Enter one language code and absolute URL per line, separated by a space. Include the current page and repeat the same set on each equivalent page.
Example
Input text
en https://example.org/en/ x-default https://example.org/
Result
<link rel="alternate" hreflang="en" href="https://example.org/en/"> <link rel="alternate" hreflang="x-default" href="https://example.org/">
Limitations
The tool checks code syntax, not whether pages exist or return reciprocal links.
Enter one language code and URL per line. Check return links on the pages themselves.