Skip to main content
PagePass home

Value of the Lang entry is not a Language-Tag

The PDF sets a language, but the value is not a valid code like en-US, so screen readers cannot pick the right voice. Replace it with a BCP 47 tag.

Drop your PDF to find "Value of the Lang entry is not a Language-Tag" in your browser. PagePass can fix it for you.

Drag and drop a PDF here, or choose a file.

Your file never leaves your browser.

Already confirmed this error? Fix this PDF in PagePass (uploads are deleted after 1 hour).

How each checker reports it

Exact wording of this error in each accessibility checker
CheckerExact messageRule / checkpoint
veraPDF (PDF/UA-1 profile)Value of the Lang entry is not a Language-Tag7.2-29
Matterhorn Protocol 1.1Natural language is not appropriate.11-007
Severity
Serious: major barrier for some users
Automatic fix
Yes: automated tagging, then a short visual review in PagePass
WCAG 2.1 success criteria
Matterhorn Protocol checkpoints
11-007

Our checker reports this as Primary language – Failed (document language not set).

What this error means

A PDF can declare its language in several places: the Lang entry of the document catalog, a Lang entry on any structure element (tag), and a Lang property on a marked-content sequence. Under ISO 32000-1, each of these must be a language identifier, which in practice means a BCP 47 tag such as en-US. veraPDF rule 7.2-29 checks every Lang value it finds and fails on any that are not well formed.

Typical bad values are display names (English), locale strings from programming languages (en_US), stray whitespace, or empty strings. These values are often written by custom report generators, older PDF libraries, or a person typing into a free-text language field in an editor.

Why it matters for screen-reader users

Screen readers use the language tag to choose a speech engine and pronunciation rules. If they can’t make sense of the value, most fall back to the user’s default voice. A French document read by an English voice is very hard to follow, and the same goes for names, places and quotations marked as another language. For braille users, the language also affects which contraction rules a braille display uses.

The document-level value supports WCAG 2.1 success criterion 3.1.1 (Language of Page, Level A). Tag-level values support 3.1.2 (Language of Parts, Level AA). A malformed value effectively means the language is not programmatically determined, so the PDF falls short of the WCAG 2.1 AA level that the ADA Title II rule requires of covered public entities.

How to confirm the fix

Run veraPDF again and confirm rule 7.2-29 no longer appears. Then spot-check with a screen reader: the voice should match the language of the text, including any passages you marked as a different language.

How to correct an invalid Lang value in Acrobat Pro

A valid value is a BCP 47 language tag: a language subtag, optionally followed by a region, such as en, en-US, es-MX, fr-CA or zh-Hans.

  1. Step 1: Check the document-level language

    Open Document Properties (hamburger menu on Windows or File menu on macOS > Document properties), go to the Advanced tab, and look at Language under Reading Options. Pick the correct language from the list, or type a valid code such as en-US.

  2. Step 2: Find tags with their own Lang value

    Invalid values often sit on individual tags rather than the document. Open the Accessibility Tags panel (View > Show/Hide > Side panels > Accessibility tags), right-click a suspect tag, choose Properties, and check the Language field.

  3. Step 3: Fix or clear the tag-level language

    Set the Language field to a valid code, or clear it when the text is in the document's main language so it inherits the document setting. Values like 'English', 'EN_US', 'en_us' or a stray space are common culprits.

  4. Step 4: Check passages marked in the Content panel

    If text was marked with a language in the Content panel, right-click it, open Properties, and correct the Language value there too.

  5. Step 5: Validate again

    Run veraPDF with the PDF/UA-1 profile. Rule 7.2-29 checks every Lang entry it finds, so keep going until none are reported.

Prevent it in the source file

Microsoft Word

  • Set the proofing language with Review > Language > Set Proofing Language before exporting. Word writes a valid code into the PDF. Avoid pasting text from sources with unusual language settings without checking them.

Custom PDF generators

  • If your PDFs come from code (reports, invoices, statements), make sure the generator writes the catalog Lang entry as a BCP 47 string such as en-US, not a display name or a locale with an underscore.

How PagePass fixes it automatically

PagePass detects the document language during layout analysis, writes a valid BCP 47 tag to the catalog Lang entry, and replaces malformed tag-level language values with valid ones (or removes them so they inherit the document language). You confirm the detected language in the Headings & Metadata tab of the 60-second visual review, and veraPDF then validates the file.

Software does about 90% of the tagging. One person on your team checks the rest in about a minute per document. veraPDF validates the result against PDF/UA-1.

Frequently asked questions

What does a valid PDF language tag look like?

It follows BCP 47 (IETF language tags): a two- or three-letter language code, optionally with a script and region, separated by hyphens. Examples: en, en-US, en-GB, es-419, pt-BR, zh-Hant-TW. Underscores, full language names and empty strings are not valid.

Is en better than en-US?

Both are valid. en-US or en-GB can help a screen reader pick a matching accent and pronunciation. The key is that the value is well formed and matches the actual text.

How is this different from a missing language?

A missing language means no Lang entry exists anywhere the text can inherit from. This error means a Lang entry exists but holds a value that is not a real language tag. The fix is similar: set a valid code.

Can a valid code still be wrong?

Yes. Tagging Spanish text as en-US passes veraPDF's syntax check but fails Matterhorn checkpoint 11-007, which a human has to review. A screen reader would read the Spanish with English pronunciation rules.