Metadata
How to set the html lang attribute
What 13x checks
This is rule metadata.lang in the public registry: html lang attribute is set and plausible. It runs on every audit, against the pages we actually fetched, and its result is derived from the response rather than estimated.
- Surface
- Metadata
- Score weight
- 5 of the readiness score
- Scope
- Runs on every audited page
- Applies
- To every site
Registry version 2026-07-30. Every rule is published, and the audit is deterministic — the same page produces the same finding every time.
The fix
The same text the audit hands you when this check fails on your own site.
Set the language on the <html> element:
<html lang="en">Use the tag that matches the content: de for German, de-AT for Austrian German, en-US for US English. If parts of the page are in another language, mark those elements individually with their own lang.
Framework-specific versions
Where the change differs enough to be worth writing out separately.
Does your site have this problem?
13x checks this and 112 others against your live URL in about 30 seconds. No account, and every finding comes with the fix for your framework.
No signup. Results in 30 seconds.
More metadata checks
- How to remove a framework default titleNo framework default titles
- Every page needs a title tagEvery page has a title
- How to fix duplicate title tagsTitles are unique per page
- How to add meta descriptionsEvery page has a meta description
- How to add hreflang for multiple languagesLanguage versions declare hreflang
- How long should a title tag beTitles are a usable length