RatedWithAI

RatedWithAI

Accessibility scanner

Form Accessibility Guide 2026: WCAG Requirements for Web Forms

Web forms are one of the highest-risk areas for accessibility failures. Inaccessible forms lock out screen reader users, keyboard users, and users with cognitive disabilities — and they generate a disproportionate share of ADA website lawsuits. This guide covers every WCAG requirement that applies to forms, common failures, and how to fix them.

Key WCAG Criteria for Forms

SC 1.3.1
Info and Relationships (AA)

Labels must be programmatically associated

SC 1.3.5
Identify Input Purpose (AA)

Common personal data fields need autocomplete

SC 1.4.3
Contrast Minimum (AA)

Label and error text needs 4.5:1 ratio

SC 2.1.1
Keyboard (A)

All form controls operable by keyboard

SC 3.3.1
Error Identification (A)

Errors identified in text, field flagged

SC 3.3.2
Labels or Instructions (A)

Every input has a persistent label

SC 3.3.3
Error Suggestion (AA)

Errors explain how to fix them

SC 3.3.4
Error Prevention (AA)

Submission confirmed, reversible, or checked

Why Form Accessibility Matters

Forms are where business happens: checkout, registration, contact, loan application, appointment booking. If a form is inaccessible, the affected user can't complete the transaction — and your business loses a customer and potentially faces legal liability.

Forms are the single most common source of accessibility complaints and lawsuits. The Accessibility for Ontarians with Disabilities Act (AODA), the European Accessibility Act (EAA), and the ADA all require accessible digital services. For forms, the practical standard is WCAG 2.1 Level AA.

Screen reader users — roughly 7.6 million Americans with visual impairments — interact with forms entirely through assistive technology. A form field without a label is announced as "edit text" with no context. An error message that isn't associated with the failed field may never be read aloud. Custom dropdowns built without ARIA are completely opaque to screen readers.

Form Labels: The Most Common Failure

Missing or broken form labels are the top form accessibility failure found in audits. WCAG 3.3.2 (Labels or Instructions) requires every input to have a label that persists while the field is filled in. WCAG 1.3.1 (Info and Relationships) requires that label be programmatically associated with the input so assistive technology can announce it.

What Counts as a Label

  • <label> element with for/id linkage — the most reliable. The for attribute on the label must exactly match the id on the input.
  • Implicit label — wrapping an input inside a <label> element creates an implicit association without needing for/id. Works well for simple forms.
  • aria-label — adds an accessible name directly to the input. Use when a visible label can't be shown (e.g., a search field with a magnifying glass icon).
  • aria-labelledby — points the input at another element by ID. Useful for complex table-based forms or grouped inputs.

What Does NOT Count as a Label

  • Placeholder text alone — disappears when typing begins. Not reliably announced by screen readers as the accessible name. Fails WCAG 3.3.2.
  • Title attribute alone — unreliable across browsers and assistive technology. The title may be treated as a tooltip, not a label.
  • Adjacent text with no programmatic association — visual proximity doesn't create an accessible relationship. The label must be linked via HTML or ARIA.

Labels for Groups of Inputs

Radio button and checkbox groups need two levels of labeling: a group label for the question, and individual labels for each option. Use <fieldset> and <legend> for this. Screen readers announce the legend text before each option inside the fieldset, giving users the question context with every answer.

Example: A group of radio buttons asking "Preferred contact method" with options "Email," "Phone," "Text" should be wrapped in a fieldset with a legend of "Preferred contact method." Without the fieldset/legend, screen readers announce each radio's label in isolation — "Email, radio button" — with no context about what question it answers.

Error Messages: Making Failures Actionable

Error handling is where most forms break for screen reader and keyboard users. WCAG has two relevant criteria: 3.3.1 (Error Identification) at Level A, and 3.3.3 (Error Suggestion) at Level AA.

WCAG 3.3.1 — Error Identification (Level A)

When a form is submitted with errors, each field that failed must be identified and described in text. The requirements are:

  • The error must be identified in text (not color alone)
  • The text must describe which field has the error
  • The error message must be programmatically associated with the failed input using aria-describedby

Using color alone to flag a failed field — turning its border red — fails this criterion because color-blind users can't distinguish the red state, and screen readers don't announce visual color.

WCAG 3.3.3 — Error Suggestion (Level AA)

When an error can be detected and a correction can be suggested, the suggestion must be provided. "Invalid entry" is not sufficient — it satisfies 3.3.1 but fails 3.3.3. The error message must tell the user what's wrong and how to fix it.

Email validation
Fails 3.3.3

Invalid email address.

Passes 3.3.3

Please enter a valid email address in the format name@example.com.

Required field
Fails 3.3.3

Field is required.

Passes 3.3.3

First name is required. Please enter your first name.

Password validation
Fails 3.3.3

Password does not meet requirements.

Passes 3.3.3

Password must be at least 8 characters and include one number.

Date format
Fails 3.3.3

Date invalid.

Passes 3.3.3

Please enter the date in MM/DD/YYYY format, for example 06/09/2026.

Focus Management After Form Errors

When a form is submitted and fails validation, focus management determines whether screen reader users even find the errors. Best practices:

  • Move focus to the first field with an error, or to an error summary at the top of the form that lists all errors as links to their respective fields.
  • Add role="alert" or aria-live="assertive" to dynamically injected error messages so screen readers announce them without the user manually navigating to them.
  • Don't clear form fields on failed submission — users should see their input and the specific errors.

Required Fields

WCAG 3.3.2 requires that required fields be identified before the user submits. Common approaches:

  • The asterisk convention — mark required fields with an asterisk (*) and include a legend at the top of the form: "Fields marked with * are required." Supplement with aria-required="true"on the input so screen readers announce "required" when the field receives focus.
  • The "optional" convention — if most fields are required, label only the optional ones as "(optional)." This reduces visual clutter while still communicating requirements.
  • HTML required attributerequired on an input triggers the browser's native validation. Also sets aria-required="true" automatically. Use this as the baseline.

Don't rely solely on color to indicate required fields (e.g., red label text for required fields, black for optional). This fails WCAG 1.4.1 (Use of Color, Level A).

Autocomplete and Input Purpose (WCAG 1.3.5)

WCAG 1.3.5 (Identify Input Purpose, Level AA) requires that inputs collecting personal information expose their purpose so browsers and assistive technology can autofill or adapt the presentation. This primarily benefits users with cognitive disabilities and motor impairments who struggle to type long personal data repeatedly.

Implementation is straightforward: add the autocomplete attribute with a value from the WCAG list of input purposes. Common values include:

Input fieldautocomplete value
First namegiven-name
Last namefamily-name
Emailemail
Phone numbertel
Street addressstreet-address
ZIP / postal codepostal-code
Credit card numbercc-number
Credit card expirycc-exp
Usernameusername
Current passwordcurrent-password
New passwordnew-password

Custom Form Controls

Custom dropdowns, date pickers, sliders, toggle switches, and multi-select components built in JavaScript need explicit ARIA roles, states, and properties to be accessible. Native HTML form elements <select>, <input type='range'>, and <input type='checkbox'> are accessible by default and should be preferred.

ARIA Patterns for Common Custom Controls

Custom dropdown / listbox

ARIA role: role="combobox" (trigger) + role="listbox" (options) + role="option" (each item)
States/properties: aria-expanded="true/false" on trigger; aria-selected="true" on selected option; aria-activedescendant pointing to focused option
Keyboard: Enter/Space opens; arrows navigate; Enter selects; Escape closes

Toggle switch

ARIA role: role="switch" on the control element
States/properties: aria-checked="true/false" reflects current state
Keyboard: Space toggles; Enter should also toggle

Date picker

ARIA role: role="dialog" on calendar popup; role="grid" on calendar table; role="gridcell" on each day
States/properties: aria-label on the dialog describing current month/year; aria-selected on selected date; aria-current="date" on today
Keyboard: Arrows navigate days; Enter selects; Escape closes; Page Up/Down change month

Slider

ARIA role: role="slider" on the draggable thumb
States/properties: aria-valuenow, aria-valuemin, aria-valuemax set to current/min/max values; aria-valuetext for non-numeric values (e.g., 'Low', 'Medium', 'High')
Keyboard: Arrows increment/decrement; Home/End jump to min/max

Form Accessibility Checklist

Complete Form Audit Checklist

Every input has a visible, persistent label — not just placeholder text
Labels are programmatically associated via <label for>, aria-label, or aria-labelledby
Required fields are marked with text or aria-required='true' — not color alone
A legend explains any required field convention (e.g., * = required)
Radio and checkbox groups use <fieldset> + <legend> for the group question
Error messages identify the field in text and describe how to fix the error
Error messages are associated to their inputs via aria-describedby
Errors are not indicated by color alone — icon or text accompanies color change
On failed submission, focus moves to first error field or an error summary
Error summary links each error back to the relevant field
All form controls are operable by keyboard — no mouse required
Custom dropdowns, date pickers, and sliders follow WAI-ARIA Authoring Practices
Personal data inputs have correct autocomplete attribute values (WCAG 1.3.5)
Label and error text meets 4.5:1 contrast ratio (WCAG 1.4.3)
Timeout warnings are given before session expiration; users can extend
Form instructions appear before inputs — not only in placeholder or tooltip
Confirmation step or clear undo mechanism for irreversible submissions (WCAG 3.3.4)

Sponsored

Also audit your site's full technical health

SEMrush Site Audit checks 130+ issues — missing alt text, broken links, slow pages. Free crawl up to 100 pages, no credit card required.

Try SEMrush Free →

Frequently Asked Questions

What WCAG criteria apply to web forms?

The primary WCAG 2.1 criteria for web forms are: 1.3.1 Info and Relationships (AA), 1.3.5 Identify Input Purpose (AA), 3.3.1 Error Identification (A), 3.3.2 Labels or Instructions (A), 3.3.3 Error Suggestion (AA), and 3.3.4 Error Prevention (AA). Together these require visible labels, meaningful error messages, and mechanisms to prevent and correct mistakes.

Do all form fields require a visible label?

Yes. WCAG 3.3.2 (Labels or Instructions) requires that form fields have labels or instructions. Placeholders alone don't satisfy this — they disappear on input, leaving users with no reference. Every input needs a persistent visible label (or, for icon-only inputs like search, a visually-hidden label that is still programmatically associated).

What makes a form error message accessible?

An accessible error message must: (1) identify which field has the error, (2) describe what went wrong in plain language, (3) be associated with the input via aria-describedby so screen readers announce it, (4) use color AND another indicator (icon, text) — not color alone, and (5) move focus to the first error or to an error summary when the form is submitted with errors.

Can I use placeholder text as a label?

No. Placeholder text fails WCAG 3.3.2 because it disappears when the user starts typing, leaving no reference. It also typically fails color contrast requirements (WCAG 1.4.3) and isn't reliably read by all screen readers in the same way as a proper label. Use a <label> element or aria-label/aria-labelledby instead.

How do I test form accessibility?

Test forms with: (1) a screen reader (NVDA+Firefox or VoiceOver+Safari) to verify labels are announced and errors are surfaced, (2) keyboard-only navigation to confirm all fields and controls are reachable, (3) an automated tool like axe or WAVE to catch missing labels and ARIA errors, and (4) a color contrast checker for label and error text. Manual testing with a screen reader is essential — automated tools miss many form accessibility issues.

Scan Your Forms for Accessibility Issues

RatedWithAI's accessibility scanner checks form labels, ARIA associations, and error handling patterns. Get a free baseline report showing exactly which forms fail WCAG and what needs to change.