Hreflang Generator
Build language and region links and x-default from a page table, and check reciprocity in the data you entered.
One version per line: the full address, a comma, then the language code, such as ar, en, or ar-SA for Arabic in Saudi Arabia. Add x-default for the page shown to everyone else.
Your result
List each language version of the page. The tags and a check appear here.
Put the same tags in the <head> of every version listed
How to use it
- Type url, language lines.
- Keep each language unique.
- Copy the link tags.
Examples
- English and Arabichttps://smart.example/en, en and the Arabic URL, ar <link rel="alternate" hreflang="en" href="https://smart.example/en"> <link rel="alternate" hreflang="ar" href="https://smart.example/ar">
- x-defaulthttps://smart.example, x-default <link rel="alternate" hreflang="x-default" href="https://smart.example">
- A regionhttps://smart.example/en-gb, en-GB <link rel="alternate" hreflang="en-GB" href="https://smart.example/en-gb">
Tool details and privacy
List each language version of a page as address, language. The page writes the alternate link tags and checks for repeated languages, a missing x-default, and wrong region codes.
Tags from a table are not proof that the other pages point back.
Options
- Codes such as ar, en, ar-SA, en-GB, or x-default. Case is fixed for you.
- Either order works on a line: address, code or code, address.
Limits
- The pages are not opened.
- Every version must carry the same set of tags; this page cannot check the other pages.
Privacy
What you type stays in your browser. Nothing is uploaded or saved on the server.
Questions
Does this crawl the pages?
No.
Can the same language appear twice?
No. It is marked Fix.
What is x-default?
The page for visitors whose language is not listed.
Are the addresses uploaded?
No.