Why it matters
Users with cognitive and learning disabilities may not understand generic error messages. Specific suggestions help all users correct mistakes quickly and reduce form abandonment.
Common violations
- Date fields that say 'invalid format' without specifying the expected format
- Email validation that says 'invalid' without suggesting corrections
- Password fields that list requirements only after failed submission
- Dropdown selections that error without suggesting valid options
Code examples
Bad
<input type="email" aria-invalid="true">
<p class="error">Invalid input</p>Good
<input type="email" aria-invalid="true" aria-describedby="email-err">
<p id="email-err" class="error">Please enter a valid email address, e.g., name@example.com</p>How to fix
Provide specific, actionable suggestions when errors are detected. Show expected formats, offer 'did you mean?' corrections, and list valid options when possible. Always associate suggestions with the relevant field.
Related criteria
Related resources
Scan your site