Language of Page
The default human language of each Web page can be programmatically determined.
Screen readers and other automated tools need to be told what the language of the page is so it can distinguish between words and pronunciations. For example, "manger" is a very different word in French than it is in English.
Way to fix
Add the lang
attribute to the html
tag to specify the language of the page.
<html lang="fr">
<body>Nous allons manger des fruits</body>
</html>
<html lang="en">
<body>He was given fruits in the manger</body>
</html>
It is also possible to add the lang
attribute to a specific element to specify the language of that element to satisfy
the WCAG 3.1.2 (opens in a new tab) requirement.