Skip to content

Rule · Accessibility

ARIA toggle has no accessible name

a11y/aria-toggle-field-nameerrorvoid a11yupdated

Why it matters

Custom checkbox, radio, switch and menuitemcheckbox elements without a name are announced only as "checkbox, not checked" with no subject.

How to fix it

Reference visible label text with aria-labelledby, or add aria-label. Prefer a native <input type="checkbox"> with a <label>.

References

void a11y reports 48 rules in this category. WCAG 2.2 AA through axe-core, plus checks axe can't do alone: visible keyboard focus, 24/44px target size on mobile, 320px reflow and disabled zoom.