- Success Criterion 3.1.1
- Conformance level A
Page’s Declared Language Not Matching Its Actual Content
3.1.1 — Language of Page
Scenario
Setting
A streaming music app's search results
What’s wrong
Wrong lang (template shipped lang="en" on a Hindi/Arabic/French site) — screen readers use wrong speech synthesizer.
Example
<html lang="en">
<body>
<h1>खोज परिणाम</h1>
<p>आपके लिए 24 गाने मिले</p>
</body>
</html> Why it matters
A screen reader applies English pronunciation rules to these Hindi search results, turning song counts and titles into unintelligible noise.
How to test
Check the html lang attribute against the page's actual content language: a template shipping lang="en" on a Hindi/Arabic/French page fails.
How to fix
When a template is reused across locales, set the lang attribute per locale build, never hard-code it once in the base template.
<html lang="hi">
<body>
<h1>खोज परिणाम</h1>
<p>आपके लिए 24 गाने मिले</p>
</body>
</html> Outcome
A Hindi-speaking listener hears their search results read naturally and finds the right song immediately.
Who is affected
Screen reader users searching in Hindi need the correct language engine, not one built for English phonetics.
Learn more
- Understanding Understanding document (opens in a new tab)
Related scenarios
- Page Published With No Language Declared in the Code
- HTML Element Missing Its Language Attribute Entirely
- Language Attribute Set to an Invalid or Malformed Value
- Language Switcher That Doesn’t Update the Page’s Lang Attribute
- Language Attribute Set on the Body Instead of the HTML Root
- Multilingual Site Serving Every Locale With the Same Lang Value