Neova고급 SEO 플랫폼

ARIA 속성 값이 잘못됨

Neova에서는 크롤링 자체에서 실행됩니다. 따로 설정할 것이 없습니다.

규칙 최종 검토: 2026년 10월 17일 · 가이드 업데이트: 2026년 7월 7일

WCAG 4.1.2는 상태와 속성에 유효한 값을 요구합니다. 스크린 리더는 잘못된 값이나 존재하지 않는 id에 대한 참조에 의존할 수 없습니다.

해 볼 수 있는 조치

true나 false처럼 속성이 허용하는 값을 쓰고, 참조는 실제로 있는 id를 가리키게 하세요.

Neova가 플래그를 지정하는 이유

  • aria-expanded="yes"처럼 허용되지 않는 값을 가진 ARIA 속성은 무시되거나 잘못 해석됩니다.
  • 존재하지 않는 id를 참조하면 레이블이나 설명이 비어 버립니다.
  • WCAG 4.1.2(A 수준)는 상태와 속성의 값이 유효해야 한다고 요구합니다.

출처

전체 가이드

이 부분은 현재 영어로만 제공됩니다.

What This Check Flags

This rule fires when an ARIA attribute is spelled correctly but its value is wrong for the type that attribute accepts — a boolean set to "yes", an ID reference pointing at an element that doesn’t exist, a token like aria-current="page-two" that isn’t in the allowed list, or a number outside its range. This is the value being invalid, not the attribute name. A bad value is often worse than a missing one: assistive tech may ignore the whole attribute, so a control silently loses its checked, expanded, or current state without any visible clue.

Here’s the part that makes this failure sneaky: it fails silently and it fails invisibly. There’s no red console error, nothing looks broken on screen, and the attribute is right there in the DOM inspector looking perfectly reasonable. But the browser’s ARIA parser reads aria-expanded="expanded", decides that isn’t a valid boolean, and throws the whole attribute away. Now your disclosure widget never announces whether it’s open or closed, and you won’t notice unless you’re actually driving the page with a screen reader. The gap between “looks fine” and “is fine” is exactly what this check exists to close.

A Real Failing Snippet, and the Fix

Here’s a nav item and a toggle that each carry a mistyped value:

<!-- FAILS: "true" isn't a valid aria-current token;
     "expanded" isn't a valid boolean -->
<a href="https://example.com/pricing" aria-current="true">Pricing</a>
<button aria-expanded="expanded">Menu</button>

The attribute names are perfectly valid — the values aren’t. aria-current takes a specific token set (page, step, true…), and while true is legal for it, on a current nav item you want page. aria-expanded is a strict boolean, so it must be true or false:

<!-- PASSES: values match each attribute's value type -->
<a href="https://example.com/pricing" aria-current="page">Pricing</a>
<button aria-expanded="false">Menu</button>

The gotcha that catches people: ARIA booleans are the strings "true"/"false", not the HTML style where the attribute’s mere presence means true. Writing aria-expanded with no value, or with "1", or with an empty string, is invalid.

ARIA Value Types and What They Accept

Every ARIA attribute has a declared value type. Match the value to the type and this check passes.

Value Type Accepts Example Attributes
true/false Exactly true or false aria-expanded, aria-hidden, aria-modal
tristate true, false, or mixed aria-checked, aria-pressed
token One value from a fixed list aria-current, aria-live, aria-sort
ID reference An id that exists on the page aria-labelledby, aria-controls
number / integer A numeric value, in range aria-valuenow, aria-level, aria-setsize
string Free text aria-label, aria-valuetext

How to Detect It

  1. axe DevTools: the “ARIA attributes must conform to valid values” violation names each attribute and shows the invalid value it found alongside the value type it expected.
  2. Lighthouse: run the Accessibility audit; this appears in the ARIA group with each non-conforming attribute listed on its element.
  3. ARIA DevTools / accessibility tree: inspect the element and compare its computed states against the DOM. If a state you set isn’t reflected in the tree, the value was rejected as invalid.

How to Fix It

  1. Read the violation to see the offending attribute and the value type it expects.
  2. For booleans and tristates, use the exact string true/false/mixed — not 1, yes, or a bare attribute.
  3. For token attributes, pick a value from that attribute’s allowed list.
  4. For ID-reference attributes, confirm the target id actually exists and is unique on the page.
  5. For numeric attributes, keep the value within the valid range (e.g. aria-valuenow between min and max).
  6. Re-scan and verify the state now appears correctly in the accessibility tree.

The most reliable way to stop these at the source is to stop generating the strings by hand. When a framework binds aria-expanded={isOpen} to a real boolean, you can’t accidentally ship "expanded" — the value is always true or false. The failures cluster around string interpolation and templating, where aria-checked="{{status}}" happily emits whatever status holds, valid token or not. If you keep tripping this check, audit the templates that build these attributes rather than the individual elements; the bug is usually upstream in one helper, not scattered across fifty components.

If the problem turns out to be a misspelled attribute name rather than a bad value — aria-lable, aria-role — that’s a different failure covered by elements must only use allowed ARIA attributes.

FAQ

What’s the Difference Between an Invalid Value and an Invalid Attribute?

An invalid value means the attribute exists but you gave it something it can’t accept (aria-checked="checked"). An invalid attribute means the name itself is wrong or misspelled. This check is only about values — the name half lives in allowed ARIA attributes.

Why Is a Bad Value Worse Than Leaving the Attribute Off?

When a value is invalid, assistive tech often discards the entire attribute, so the control loses that state entirely and with no warning. A toggle that should announce “pressed” simply won’t.

Can I Use HTML-Style Boolean Attributes With ARIA?

No. In HTML, disabled is true just by being present. ARIA booleans must carry the explicit string value "true" or "false" — presence alone is invalid.

Is aria-current="true" Wrong?

Not strictly — true is one of the accepted tokens for aria-current. But on a navigation link marking the current page, page is more precise and announces better. Reserve true for cases with no more specific token. Related roles’ value rules interact with the containment checks too.

내 사이트에서 찾아보기

Neova는 크롤링할 때마다 이 점검과 다른 모든 점검을 실행하고, 수정 방법을 팀을 위한 티켓으로 작성합니다.

  • Mac, Windows, Linux용 데스크톱 앱
  • 출처가 함께 있는 696개 점검 전체
  • Search Console과 Analytics 4를 읽기 전용으로 연결
  • Jira, Linear, Asana로 티켓 보내기

Neova 다운로드 Desktop Free 플랜 또는 Solo 14일 무료, 카드 불필요.

접근성 점검 전체 · 가이드 · 점검 라이브러리

작성: Neova Labs · 점검 라이브러리로 돌아가기