Skip to contentSkip to content

Mechanics module WCAG 3.1.1 Level A

Language attribute

Sets correct `lang` attributes at the HTML root and element level for foreign language passages.

What it does

Function in one sentence — and in three sentences

For screen readers to pronounce texts correctly, they need the correct `lang` value. If this is missing, the software will read an English term in a German text with a German pronunciation—intelligible only to the reader who already knows the original term.

The module first sets the global `lang="de"` to `` (if not already set), then recognizes foreign language passages and marks them correctly.

This is how the plugin implements it.

Technical measures

  • set root-`lang`: automatically derive from WordPress `get_bloginfo("language")`.
  • Foreign language recognition: simple patterns (e.g. „Privacy Policy", „SaaS", „onboarding") → `lang="en"`.
  • Inline span wrapping: recognized terms are marked with `` enclosed.
  • Multilingual plugin integration: With WPML / Polylang, pages are delivered in the respective language with the correct `lang`.
  • Override configuration: Manual list of foreign language terms can be maintained.
In the plugin backend

You can find these settings in the module tab.

  • Read or manually set the root path from WP settings.
  • Auto-Span-Wrap on/off
  • Expand pattern list for auto-detection (default ~150 terms)
  • Multilingual plugin: Auto-detect (WPML, Polylang, MultilingualPress) or select manually.

Path in Admin: WP-Admin → Accessibility → Modules → Language Attribute

When do you need the module?

Use case

A mandatory root for every page (root-`lang`). Inline wrapping is especially important for sites with many English technical terms — tech blogs, marketing sites, agencies.

Related modules

That fits together thematically.

  • AI Easy Language

    WCAG 3.1.5

    Translates complex content into DIN-SPEC-33429 compliant plain language — as a frontend toggle for visitors.

  • Heading hygiene

    WCAG 1.3.1

    Detects and corrects skipped heading levels, duplicate H1s, and missing structure.

  • ARIA Manager

    WCAG 4.1.2

    Automatically assigns correct ARIA roles, states, and properties to interactive elements.

Activate the module for your site?

In the initial 15-minute consultation, we will clarify whether the module is relevant for your theme and content type — and what the setup looks like.

15-minute initial consultation
View all modules

Easy language