[aria-*] attributes have valid values

Accessibility attributes use valid values so screen readers can interpret them.

On this page

Impact

ScanGov impact ratings

About

Assistive technologies, like screen readers, can't interpret ARIA attributes with invalid values.

Risks

Screen readers cannot interpret attributes with unrecognized values.

Why it's important

Ensures assistive technologies like screen readers can correctly interpret and announce page elements to users with disabilities.

User stories

As a screen reader user, I want ARIA attributes to be correctly implemented so that I can understand the purpose and state of interactive elements.

Code

Failing pattern:

<!-- Fail: aria-haspopup value is not in the allowed set -->
<button aria-haspopup="yes">Open menu</button>

Passing pattern:

<!-- Pass: valid aria-haspopup value -->
<button aria-haspopup="menu">Open menu</button>

Error

ScanGov messaging when a site fails a standard:

Failed: [aria-*] attributes have valid values

Guidance

Indicators

On this page