Automated Accessibility Audits: The PageBolt /audit Endpoint
You just deployed a new feature. Everything looks great. But you forgot to test one thing: accessibility.
A week later, a customer reports: "Your new page is completely unusable with a screen reader." Another customer: "The color contrast is too low, I can't read it."
You scramble to fix it. Now you're patching live code. The feature could have shipped accessible if you'd just run an audit before release.
Here's the reality: 95% of websites fail accessibility checks. It's not because developers are careless. It's because accessibility testing isn't automated. It's manual, tedious, and easy to skip.
The Problem: Manual Accessibility Testing
Right now, your accessibility workflow probably looks like:
- Developer manually clicks through pages
- Browser extensions run axe, highlight violations
- Developer fixes them manually
- QA tests screen reader (if you have time)
- Edge cases slip through
It's slow. It's incomplete. Violations ship to production.
The Solution: /audit Endpoint
PageBolt's /audit endpoint runs axe-core (the industry standard) on any URL and returns violations organized by severity.
const response = await fetch('https://api.pagebolt.com/v1/audit', {
method: 'POST',
headers: {
'Authorization': `Bearer YOUR_API_KEY`,
'Content-Type': 'application/json'
},
body: JSON.stringify({
url: 'https://yoursite.com/new-feature'
})
});
const data = await response.json();
console.log(data.violations);
// Returns: [
// { severity: 'critical', count: 2, violations: [...] },
// { severity: 'serious', count: 5, violations: [...] },
// { severity: 'minor', count: 12, violations: [...] }
// ]
One API call. Full accessibility audit. Violations sorted by severity.
Real Example: CI/CD Accessibility Gate
You want to enforce accessibility in your deployment pipeline. No feature ships without passing accessibility checks.
const axios = require('axios');
async function auditPageBeforeDeploy(stagingUrl) {
console.log(`Running accessibility audit on ${stagingUrl}...`);
const response = await fetch('https://api.pagebolt.com/v1/audit', {
method: 'POST',
headers: {
'Authorization': `Bearer ${process.env.PAGEBOLT_API_KEY}`,
'Content-Type': 'application/json'
},
body: JSON.stringify({
url: stagingUrl,
standard: 'wcag2aa' // or wcag21aa, section508
})
});
const audit = await response.json();
// Check for critical violations
const critical = audit.violations.find(v => v.severity === 'critical');
if (critical && critical.count > 0) {
console.error(`❌ DEPLOYMENT BLOCKED: ${critical.count} critical accessibility violations`);
critical.violations.forEach(v => {
console.error(` - ${v.description}`);
console.error(` Impact: ${v.impact}`);
console.error(` Fix: ${v.remediation}`);
});
process.exit(1);
}
const serious = audit.violations.find(v => v.severity === 'serious');
if (serious && serious.count > 0) {
console.warn(`⚠️ Warning: ${serious.count} serious violations (review before shipping)`);
}
console.log(`✅ Accessibility check passed`);
return true;
}
// In your GitHub Actions workflow
await auditPageBeforeDeploy(process.env.STAGING_URL);
// Runs as part of CI/CD. Fails the build if violations found.
What /audit Returns
{
"url": "https://yoursite.com/page",
"tested_at": "2026-03-18T14:32:00Z",
"passes": 25,
"violations": [
{
"severity": "critical",
"count": 2,
"violations": [
{
"id": "color-contrast",
"description": "Background and foreground colors do not have sufficient contrast",
"elements_affected": 3,
"impact": "Users with low vision cannot read the text",
"remediation": "Change text color to #000000 or background to #ffffff",
"help_url": "https://dequeuniversity.com/rules/axe/..."
}
]
},
{
"severity": "serious",
"count": 5,
"violations": [...]
}
]
}
Full details for every violation. Severity, element count, remediation guidance.
Use Cases
Deploy gate: Block deployments if critical violations detected
Compliance: Prove WCAG 2.1 AA compliance to auditors (screenshot + audit report)
Competitor monitoring: Audit competitor sites, compare accessibility maturity
Bulk auditing: Audit 100 pages weekly, track progress over time
Team accountability: Engineering dashboard showing accessibility violations by page
Customer demands: Enterprise customers often require accessibility certification
Cost vs. Manual Testing
Manual approach:
- Developer time: 30 min per page
- Coverage: ~70% of violations caught
- Cost: 5 pages/week × 0.5 hours × $150/hr = $375/week
/audit approach:
- API call: <1 second per page
- Coverage: ~95% of violations caught (axe-core standard)
- Cost: $29/month (Starter) = $1.50/audit if doing 500/month
Annual savings: $19,000+ if auditing 5 pages/week
Plus: automated audits catch issues before they ship. Manual testing catches them in production.
Standards Supported
- WCAG 2.0 Level A / AA / AAA
- WCAG 2.1 Level A / AA / AAA
- Section 508
- Best practices
Getting Started
- Sign up at pagebolt.dev/pricing
- Get your API key
- POST a URL to
/audit - Integrate into CI/CD or run manually before release
Accessibility isn't a feature. It's a requirement. Make it automatic.
Start free: pagebolt.dev/pricing. 100 audits/month, no credit card required.
For compliance teams: PageBolt /audit + screenshot audit trails = WCAG certification ready. Document every violation fixed, prove progress to regulators.
Top comments (0)