Skip to content
EN/FR
Contact
← All guides
A LITTLE MORE EMDASH

Language and hreflang for EmDash

Practical steps for your EmDash website and Astro frontend.

Set the document language

Set the HTML lang attribute to the language of each page, such as en or fr. This helps browsers and assistive technology interpret your content. A multilingual site still needs a language on every document.

Link equivalent translations

Add alternate hreflang links in the Astro page head for equivalent translations, including the current page. Use absolute production URLs, reciprocal links and a self-referencing canonical for each translation. x-default can identify the default language selection page. Do not link unrelated pages as translations.

Explore the tools