WCAG Accessibility Scanner
Automated accessibility auditing via headless browser. Run WCAG 2.1 AA checks and get structured reports with violations, severity levels, and remediation guidance.
/api/wcag-scan
Compliance
Why use WCAG Scanner?
Renders URLs in a headless Chromium browser, runs WCAG 2.1 AA compliance checks via axe-core, and returns structured JSON reports with violations, severity levels, CSS selectors for targeting issues, and actionable remediation tips. Supports EN 301 549 for European Accessibility Act compliance.
What it does
The WCAG Accessibility Scanner performs comprehensive accessibility audits on any public webpage. Using a headless Chromium browser and the industry-standard axe-core testing engine, it evaluates pages against WCAG 2.1 Level AA criteria—the gold standard for web accessibility compliance.
Each scan produces a detailed JSON report containing categorized results: violations (issues that must be fixed), passes (requirements met), and incomplete (manual review needed). Every violation includes the specific WCAG guideline reference, severity level, CSS selector for the affected element, and step-by-step remediation guidance.
Key Features
- Headless browser rendering — Tests the actual DOM after JavaScript execution
- axe-core integration — Industry-standard accessibility testing engine
- Multiple standards — WCAG 2.0 A/AA/AAA, WCAG 2.1 AA, best-practice, and EN 301 549 (EAA)
- Selective scanning — Include or exclude specific CSS selectors from the audit
- Overall grading — Automatic A/B/C/D/F grade based on violation severity
Code Examples
curl -X POST https://api.atomicapis.dev/api/wcag-scan \
-H "X-RapidAPI-Proxy-Secret: YOUR_SECRET" \
-H "Content-Type: application/json" \
-d '{
"url": "https://example.com",
"standard": "wcag21aa",
"timeout": 15000,
"waitForIdle": true
}'
Request Parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
url |
string | Required | The URL to scan (must be absolute HTTP/HTTPS) | "https://example.com" |
standard |
string | Optional | Accessibility standard: wcag2a, wcag2aa, wcag2aaa, wcag21aa, best-practice. Default: wcag21aa |
"wcag21aa" |
tags |
string[] | Optional | Filter by specific WCAG tags | ["wcag2aa"] |
includeSelectors |
string[] | Optional | CSS selectors to include in the scan | ["main", "#content"] |
excludeSelectors |
string[] | Optional | CSS selectors to exclude from the scan | [".ad-banner"] |
timeout |
integer | Optional | Timeout in milliseconds (5000-30000). Default: 15000 | 15000 |
waitForIdle |
boolean | Optional | Wait for network idle before scanning. Default: true | true |
Response Format
{
"url": "https://example.com",
"standard": "wcag21aa",
"summary": {
"totalViolations": 3,
"critical": 0,
"serious": 1,
"moderate": 2,
"minor": 0,
"overallGrade": "C"
},
"violations": [
{
"id": "color-contrast",
"impact": "serious",
"description": "Elements must have sufficient color contrast",
"help": "...",
"helpUrl": "...",
"wcagTags": ["wcag2aa", "wcag143"],
"en301549": null,
"nodes": [
{
"html": "<p class='light-text'>...",
"target": ".light-text",
"failureSummary": "Fix any of the following: Element has insufficient color contrast..."
}
]
}
],
"passes": [
{
"id": "html-lang-valid",
"description": "...",
"nodeCount": 1
}
],
"incomplete": 0,
"inapplicable": 5,
"scanDurationMs": 3200.5
}
Response Fields
| Field | Type | Description |
|---|---|---|
url |
string | The URL that was scanned |
standard |
string | Accessibility standard used for the scan |
summary |
object | Summary with totalViolations, critical/serious/moderate/minor counts, and overallGrade (A/B/C/D/F) |
violations |
array | Accessibility violations found with id, impact, description, wcagTags, and affected nodes |
passes |
array | Rules that passed with id, description, and nodeCount |
incomplete |
number | Count of rules that could not be fully evaluated |
inapplicable |
number | Count of rules that did not apply to the page |
scanDurationMs |
number | Time taken to complete the scan in milliseconds |
Use Cases
Compliance Auditing
Ensure your website meets legal accessibility requirements. Generate audit reports for ADA, Section 508, or EAA compliance documentation.
CI/CD Integration
Automate accessibility testing in your deployment pipeline. Block releases that introduce new violations and track accessibility scores over time.
Agency Reporting
Scan multiple client websites and generate comprehensive accessibility reports. Loop through URLs programmatically to audit entire portfolios efficiently.
Build Constraints
Headless Chromium
Uses Puppeteer with headless Chromium for accurate DOM rendering. Shares infrastructure with Ghost Browser Screenshot API for efficient resource utilization.
axe-core (MIT)
Powered by Deque's axe-core testing engine. Industry-standard accessibility rules with regular updates and comprehensive coverage.
EN 301 549 Mapping
Full support for European Accessibility Act requirements. EN 301 549 standard maps to WCAG 2.1 AA with additional European-specific criteria.
Configurable Scope
Fine-tune scans with include/exclude CSS selectors, custom tags, adjustable timeouts, and network idle detection for accurate results on dynamic pages.
Error Codes
| Code | Status | Description | Resolution |
|---|---|---|---|
400 |
Bad Request | Invalid or missing URL, invalid URL format, page load timeout, or scan error | Verify the URL is a valid absolute HTTP(S) URL, is reachable, and loads within the timeout |
401 |
Unauthorized | Invalid or missing API key | Include valid Authorization header |
500 |
Server Error | Internal processing error | Retry request or contact support |
Ready to scan for accessibility?
Start auditing your websites for WCAG compliance today. Get your API key and make your web content accessible to everyone.