skills/a11y/SKILL.md
Systematically audit and remediate accessibility issues in UI, focusing on keyboard navigation, screen reader support, color contrast, semantic HTML, ARIA usage, and motion sensitivity. Use when the user wants to improve accessibility, make a component accessible, fix WCAG violations, add keyboard support, or ensure screen reader compatibility.
npx skillsauth add aladicf/better-web-ui a11yInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Systematically improve accessibility so the interface works for users with disabilities, temporary impairments, and assistive technology.
This skill focuses on remediation and implementation, not just scoring. It complements audit (which measures across dimensions) and harden (which handles edge cases broadly). Use this when accessibility is the primary goal.
Users start this workflow with /a11y. Once this skill is active, load $frontend-design — it contains design principles, anti-patterns, and the Context Gathering Protocol. Follow that protocol before proceeding — if no design context exists yet, you MUST load $setup first.
Consult the accessibility testing reference for automated tool integration (axe, WAVE, Pa11y) and CI workflow guidance. Consult the colorblindness UX reference when color is carrying meaning in states, charts, or validation. Consult the component accessibility reference for keyboard support, focus handling, skip links, and hidden content patterns. Consult the interaction design reference for focus, loading, transitions, and feedback states. Consult the semantic color reference when checking whether color communicates state or just decoration. Consult the responsive design reference when accessibility needs to adapt across small screens, touch contexts, or zoom levels.
Identify what is broken and who it affects:
Run automated checks first:
Test keyboard navigation manually:
Test with a screen reader:
Check visual accessibility:
Check motion and animation:
prefers-reduced-motion and confirm the interface remains usableUse the right element for the job. Native HTML elements come with built-in accessibility.
Fixes:
<div> or <span> buttons with <button> elements<a> only for navigation, <button> for actions<nav>, <main>, <aside>, <header>, <footer> for landmarks<ul> / <ol> for lists, not styled divs<table> for tabular data, not CSS grid layouts<label> explicitly associated with inputs via for attribute<fieldset> and <legend> for related form groupsAnti-patterns to remove:
role, tabindex, and keyboard handlers<h1> through <h6> should reflect document structure)Every interactive element must be reachable and operable without a mouse.
Fixes:
tabindex="0" (or are naturally focusable)tabindex="-1" from elements that should be focusabletabindex values (they create unpredictable order)outline: none without replacementFocus must be intentional, visible, and predictable.
Fixes:
Use ARIA only when native HTML is insufficient. ARIA does not change behavior, only semantics.
When to use ARIA:
Common ARIA fixes:
role="dialog" and aria-modal="true" to modalsaria-expanded to disclosure buttons and accordion triggersaria-current="page" to the active navigation itemaria-live="polite" or aria-live="assertive" to status containersaria-label or aria-labelledby to icons and icon-only buttonsaria-describedby to inputs with helper text or error messagesaria-invalid="true" to invalid form fieldsARIA anti-patterns:
role="button" to actual <button> elementsaria-hidden="true" on focusable elementsrole="button" on a link)Ensure information is perceivable regardless of visual ability.
Fixes:
Ensure assistive technology users receive equivalent information.
Fixes:
aria-live regions for dynamic updates (search results, form submissions, notifications)aria-describedbyaria-hidden="true" or role="img" with a titleth headers and scope attributesRespect users who cannot tolerate or do not want motion.
Fixes:
@media (prefers-reduced-motion: no-preference) or provide reduced-motion alternativesprefers-reduced-motion: reduce, replace motion with instant state changes or subtle fadesAfter remediation, verify that fixes work:
prefers-reduced-motion and confirm the interface is still usableprefers-reduced-motionNEVER:
Remember: accessible design is usable design. Fixing accessibility issues usually improves the experience for everyone.
development
Build or improve a UI testing strategy covering visual regression, interaction testing, and accessibility assertions. Use when the user asks to add tests, set up testing, fix flaky tests, improve test coverage, validate UI behavior, catch visual bugs, or establish confidence in shipping frontend changes.
development
Design security-conscious interfaces that protect users without frustrating them. Use when the user asks about MFA, password UX, breach notifications, trust indicators, secure forms, account recovery, or making security feel safe rather than scary.
development
Design or improve search experiences, result presentation, and filtering interfaces. Use when the user asks to add search, redesign search results, improve findability, build autocomplete, add filters, or fix zero-results dead ends.
development
Plan, implement, or improve an internationalization and localization strategy for UI content, formatting, and regional adaptation. Use when the user asks to add i18n, localize, translate, support multiple languages, handle regional formats, manage locale switching, or build a multilingual product.