Skip to main content
skill CX Codex

accessibility-testing · aj-geddes — Claude Code skill: WCAG and a11y tests

A skill that walks your agent through WCAG checks: axe scans, keyboard navigation, ARIA, screen readers. Useful when a project has to meet a11y requirements.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add aj-geddes/useful-ai-prompts --skill accessibility-testing -a claude-code
Open on GitHub

What accessibility-testing does

The skill hands your agent ready-made accessibility testing recipes. It ships a minimal @playwright/test example built on @axe-core/playwright: open the page, run the scanner with the wcag2a, wcag2aa, wcag21a and wcag21aa tags, then assert the violations list is empty. Narrow the scan to one region, like nav, the same way.

Under references/ sit longer guides: axe-core with Playwright, keyboard navigation testing, ARIA testing, Jest with jest-axe, Cypress, and Python with Selenium and axe. Pick the one matching your stack.

One caveat the author states outright: automated tests catch roughly 30-40% of issues. Manual screen reader passes and a keyboard-only walkthrough stay on your list, otherwise a chunk of barriers never shows up. The skill runs in Claude, Codex, Cursor, GitHub Copilot, Gemini CLI and OpenCode.

What it helps with

  • run an axe scan on a page and get the WCAG A and AA violations
  • check that the UI works with a keyboard alone, no focus traps
  • catch broken ARIA attributes before release
  • wire contrast and text alternative checks into CI
  • find a working example for Jest, Cypress or Selenium

Example prompts for the agent

  • run an axe scan on the homepage and list WCAG AA violations
  • test keyboard navigation through the login form
  • write a jest-axe test for the cart component

How to install accessibility-testing

1Skills CLI (Vercel)

npx skills add aj-geddes/useful-ai-prompts --skill accessibility-testing -a claude-code

2Manually: put the files in place

~/.claude/skills/accessibility-testing/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/accessibility-testing/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about accessibility-testing

How do I install accessibility-testing in Claude?

Run npx skills add aj-geddes/useful-ai-prompts --skill accessibility-testing -a claude-code. The skill file lands at ~/.claude/skills/accessibility-testing/SKILL.md.

What does the accessibility-testing skill do?

It gives the agent templates and guides for testing web app accessibility: axe-core scans, keyboard navigation, ARIA, contrast, and screen reader compatibility.

Are automated tests enough for accessibility?

No. The skill's author puts automated coverage at around 30-40% of issues, so manual screen reader checks and a keyboard-only pass are still needed.

Source text

SKILL.md · MIT
---
name: accessibility-testing
description: >
  Test web applications for WCAG compliance and ensure usability for users with
  disabilities. Use for accessibility test, a11y, axe, ARIA, keyboard
  navigation, screen reader compatibility, and WCAG validation.
---

# Accessibility Testing

## Table of Contents

- [Overview](#overview)
- [When to Use](#when-to-use)
- [Quick Start](#quick-start)
- [Reference Guides](#reference-guides)
- [Best Practices](#best-practices)

## Overview

Accessibility testing ensures web applications are usable by people with disabilities, including those using screen readers, keyboard navigation, or other assistive technologies. It validates compliance with WCAG (Web Content Accessibility Guidelines) and identifies barriers to accessibility.

## When to Use

- Validating WCAG 2.1/2.2 compliance
- Testing keyboard navigation
- Verifying screen reader compatibility
- Testing color contrast ratios
- Validating ARIA attributes
- Testing form accessibility
- Ensuring focus management
- Testing with assistive technologies

## Quick Start

Minimal working example:

```typescript
// tests/accessibility/homepage.a11y.test.ts
import { test, expect } from "@playwright/test";
import AxeBuilder from "@axe-core/playwright";

test.describe("Homepage Accessibility", () => {
  test("should not have any automatically detectable WCAG A or AA violations", async ({
    page,
  }) => {
    await page.goto("/");

    const accessibilityScanResults = await new AxeBuilder({ page })
      .withTags(["wcag2a", "wcag2aa", "wcag21a", "wcag21aa"])
      .analyze();

    expect(accessibilityScanResults.violations).toEqual([]);
  });

  test("navigation should be accessible", async ({ page }) => {
    await page.goto("/");

    const results = await new AxeBuilder({ page }).include("nav").analyze();

    expect(results.violations).toEqual([]);
  });

// ... (see reference guides for full implementation)
```

## Reference Guides

Detailed implementations in the `references/` directory:

| Guide | Contents |
|---|---|
| [axe-core with Playwright](references/axe-core-with-playwright.md) | axe-core with Playwright |
| [Keyboard Navigation Testing](references/keyboard-navigation-testing.md) | Keyboard Navigation Testing |
| [ARIA Testing](references/aria-testing.md) | ARIA Testing |
| [Jest with jest-axe](references/jest-with-jest-axe.md) | Jest with jest-axe |
| [Cypress Accessibility Testing](references/cypress-accessibility-testing.md) | Cypress Accessibility Testing |
| [Python with Selenium and axe](references/python-with-selenium-and-axe.md) | Python with Selenium and axe |

## Best Practices

### ✅ DO

- Test with real assistive technologies
- Include keyboard-only users
- Test color contrast
- Use semantic HTML
- Provide text alternatives
- Test with screen readers
- Run automated tests in CI
- Follow WCAG 2.1 AA standards

### ❌ DON'T

- Rely only on automated tests (they catch ~30-40% of issues)
- Use color alone to convey information
- Skip keyboard navigation testing
- Forget focus management in dynamic content
- Use div/span for interactive elements
- Hide focusable content with display:none
- Ignore ARIA best practices
- Skip manual testing

© aj-geddes · MIT · aj-geddes/useful-ai-prompts

Similar skills

All skills for Testing and QA →

accessibility-testing by other authors comes first.

From the same set143

database-query-optimization A skill that walks your agent through slow SQL: execution plans, indexes, and where the time actually goes. Useful when the database drags. CX Codex +1 586installs database-backup-restore A coding assistant skill for backup and disaster recovery strategies. Use it when planning backups, testing restore procedures, or setting up automated backup jobs. CX Codex +1 582installs memory-leak-detection A skill for tracking down memory leaks: heap snapshots, profiling and the usual patterns behind growing memory use. CX Codex +1 580installs technical-roadmap-planning Builds a technical roadmap across quarters and years: architecture, infrastructure, stack investments. Useful before a big modernization push. CX Codex +1 577installs push-notification-setup Integrates push notifications for iOS and Android using Firebase Cloud Messaging and APNs. Helps handle token refreshes, deep linking, and background sync. CX Codex +1 575installs database-schema-documentation Documents database schemas, generates Mermaid ERD diagrams, and tracks table constraints. Useful when creating data dictionaries or writing migration specs. CX Codex +1 569installs Data Visualization A skill that steers your agent toward the right chart type and gives working matplotlib and seaborn code for analysis and stakeholder decks. CX Codex +1 568installs app-store-deployment Deploys iOS and Android apps to App Store and Google Play. Guides through code signing, versioning, and pre-release verification. CX Codex +1 564installs

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor