What AuditX checks
The scan uses the Lighthouse label audit, which runs the axe-core "label" rule on the page in a real browser. It looks at every form field and checks that it has an accessible name, from a <label> element linked to it, a label that wraps it, or an aria-label or aria-labelledby attribute. The axe rule also accepts a non-empty title or placeholder attribute as a name. It passes when every field has one. It fails when at least one field has none, and the report names up to five of them with the total count. A page without form fields gets no result at all. When Lighthouse could not run this audit, the result is marked as not measured.
Why it matters
A screen reader announces a field by its label. A field without one is read out as just "edit text" or "combo box", and a blind visitor has to guess what to type.
A linked label also makes the field easier to use for everyone: clicking the label text puts the cursor in the field, which gives small checkboxes and radio buttons a larger target.
A placeholder or title alone passes this check, but it is a weak label: a placeholder disappears as soon as someone starts typing, and a title only shows on hover.
A fail counts in full toward the accessibility score.
How to fix it
- Give each field named in the report a visible <label> whose for attribute matches the id of the field, or wrap the field inside the <label>.
- If the design has no room for visible text, such as a search box next to a search button, add aria-label with a short description, or aria-labelledby pointing at text that already describes the field.
- Do not rely on a placeholder or title alone, even though it passes this check.
- Check form builders and plugins too: newsletter, contact and cookie forms are the most common places for unlabeled fields.
<label for="email">Email address</label>
<input id="email" name="email" type="email" autocomplete="email">
Does your site pass this check? A free scan runs it with every other check and shows the result in about a minute.
Scan my siteSources
- W3C WAI: Labeling Controls
- W3C: Understanding SC 3.3.2 Labels or Instructions
- MDN: The label element
- Deque: Form elements must have labels