What this rule checks
Ensure every HTML document has a lang attribute.
Why it matters
WCAG 3.1.1 requires the page language to be set.
How to fix it
On any website
- Add a lang attribute to the <html> element, for example <html lang="en">.
On Shopify
- In layout/theme.liquid, make sure the opening tag reads <html lang="{{ request.locale.iso_code }}">.
How to check the fix
- Re-scan and confirm html-has-lang passes.
How FixReports finds it
Our scan runs the axe-core rule html-has-lang in a real Chrome browser on every page it tests, and reports each failing element with its page, its markup and, where it applies, a screenshot.
An automated test confirms that this specific problem is present. It can't tell whether the rest of the page is accessible: some barriers only show up when a person checks the page.