Moderate2.1.4 Character Key Shortcuts (Level A)Rule ID: accesskeys
accesskey values must be unique and used with caution
Duplicate or poorly chosen `accesskey` values create keyboard shortcut conflicts.
Rule Description
Checks for duplicate accesskey assignments and risky keyboard-shortcut patterns.
Why It Matters
- Shortcut conflicts make controls unpredictable
- Character-key shortcuts can cause accidental activation
- Assistive technology and browser shortcuts may collide
How to Fix
Avoid accesskey unless necessary; if used, ensure uniqueness and provide documentation.
Bad Example:
<button accesskey="s">Save</button> <button accesskey="s">Submit</button>
Good Example:
<button accesskey="s">Save</button> <button accesskey="u">Upload</button>
Common Mistakes
- Reusing the same access key on a page
- Not communicating available shortcuts
- Relying on character-only shortcuts for key actions
Testing
- Audit all elements with
accesskey - Verify no duplicate values exist
- Test interaction with common browser/AT shortcut combinations
External Resources
Automate Your Accessibility Testing
Our tool automatically checks for this rule and hundreds of other accessibility issues.
Start Your Free Trial