Rule ID: ace-form-autocomplete-valid

Validate autocomplete attribute values are appropriate for the form field type

WCAG 2.1 (AA) - WCAG 2.2 (AA) 1.3.5: Identify Input Purpose Attention Deficit Blind Low Vision Deafblind Mobility Cognitive Legal Risk

What This Rule Checks

For users relying on assistive technologies, autocomplete attributes help predict and automatically fill in input values. If the autocomplete attribute is used with invalid or unsupported values, it can lead to confusion or prevent the feature from working correctly.

Who Is Affected

This issue primarily affects: Attention Deficit users, who have attention deficit-related needs; Blind users, who rely entirely on screen readers or braille displays to navigate and interact with content; Low Vision users, who may use screen magnification, custom fonts, or high-contrast modes; Deafblind users, who rely on braille displays and cannot access visual or auditory content; Mobility users, who navigate using keyboards, switches, voice control, or other assistive input devices; Cognitive users, who benefit from clear structure, simple language, and consistent navigation patterns.

Why This Matters

Valid autocomplete values enable browsers and assistive technologies to auto-fill form fields, reducing cognitive load and input effort. Users with motor disabilities or cognitive impairments benefit significantly. This is a WCAG 1.3.5 Level AA requirement.

How to Fix

Ensure that the autocomplete attribute has a valid value from the predefined list provided in HTML specifications. These values relate to common input fields such as “name,” “email,” “address,” and “tel” among others. Avoid using arbitrary or custom values not recognized by the browser.

Code Examples

Incorrect Markup Solutions:
Code example
<!-- Invalid autocomplete values --> <input type="text" autocomplete="full-name"> <!-- Should be "name" --> <input type="tel" autocomplete="phone"> <!-- Should be "tel" --> Copy
Correct Markup Solutions:
Code example
<!-- Valid autocomplete values --> <input type="text" autocomplete="name"> <input type="email" autocomplete="email"> <input type="tel" autocomplete="tel"> <input type="text" autocomplete="street-address"> Copy

Common Mistakes to Avoid

  • Using non-standard autocomplete values like “full-name” or “phone”.
  • Not matching autocomplete values to the input’s purpose.
  • Omitting autocomplete on common fields like name, email, and address.

Tip: Form accessibility is one of the most common sources of accessibility complaints. Every form control must have a programmatically associated label that is visible and descriptive. Test every form with keyboard-only navigation.

Related WCAG Criteria

  • 1.3.5: Identify Input Purpose