Abilyo by WebAbility

iOS SDK

Native accessibility testing for iOS apps. Wraps Apple's iOS 17 Accessibility Audit API + 8 custom detectors. In-app overlay, XCTest matchers, AI fix generation.

WCAG-grade accessibility testing for iOS apps. Three Swift libraries:

  • WebAbilityA11y — core auditor (Apple API + 8 custom Swift detectors)
  • WebAbilityA11yUI — in-app debug overlay (shake-to-toggle floating panel)
  • WebAbilityA11yTesting — XCTest matchers for design-system + UI tests

Install (Swift Package Manager)

dependencies: [
    .package(url: "https://github.com/snayyar00/abilyo-ios", from: "1.0.0")
]

Or in Xcode: File → Add Packages → paste the URL.

Quick start

import WebAbilityA11y
 
let auditor = WebAbilityAuditor()
let result = auditor.scan(view: rootView)
print("Score: \(result.score)/100, \(result.summary.total) issues")

XCUITest

import XCTest
import WebAbilityA11y
import WebAbilityA11yTesting
 
final class A11yTests: XCTestCase {
    func testHome() throws {
        let app = XCUIApplication()
        app.launch()
        let result = try WebAbilityAuditor().scanXCUI(app)
        XCTAssertNoCriticalA11yIssues(result)
        XCTAssertA11yScore(result, atLeast: 90)
    }
}

In-app overlay

#if DEBUG
import WebAbilityA11yUI
WebAbilityOverlay.shared.start()  // shake to toggle
#endif

What we detect

SourceWCAGWhat
Apple audit API (iOS 17+)1.4.3Contrast
Apple audit API1.1.1Missing element descriptions
Apple audit API1.4.4Dynamic type support
Apple audit API2.5.8Hit region size
Apple audit API1.4.10Text clipped
Apple audit API4.1.2Incorrect traits
Custom (iOS 15+)1.3.1Heading hierarchy
Custom2.4.3Focus order
Custom2.3.3Reduced motion compliance
Custom1.4.1Color-only meaning
Custom3.3.2Required form indicators
Custom1.1.1Missing image labels
Custom4.1.2Icon-only buttons unlabeled
Custom2.5.8Touch target size (covers all UIControl)

AI fix

let result = auditor.scan(view: rootView)
let fix = try await auditor.aiFix(for: result.issues[0], framework: .swiftui)
print(fix.alternatives[0].frameworkCode)
// → ".accessibilityLabel(\"Close\")"

Returns 1–3 alternatives with explanation, contrast ratio (for color issues), and ready-to-paste Swift code (UIKit or SwiftUI).

Visual audit (Claude vision)

For pixel-level issues that structural detectors can't catch — icon contrast, focus rings, "looks like a button but isn't" — use scanVisual or the combined scanFull:

// Visual-only — pairs with structural scan
let visual = try await auditor.scanVisual(view: rootView)
print("Visual issues: \(visual.count)")
 
// Combined — runs both, merges and dedupes
let full = try await auditor.scanFull(view: rootView, brandColors: [.brandBlue, .brandTeal])
// full.issues contains BOTH structural + visual findings

What scanVisual catches that scan misses:

  • 1.4.11 icon/border contrast (vs adjacent colors, not just text/background)
  • 2.4.7 focus indicator visibility
  • 4.1.2 affordance mismatches (looks tappable but isn't tagged)
  • 1.4.5 text rendered as images
  • 2.5.8 touch target spacing exceptions

Cost ~$0.001/screen via Claude Haiku vision. Pass brandColors so the model knows your palette and doesn't flag intentional brand colors.

Requirements

  • iOS 15+ (custom detectors and overlay)
  • iOS 17+ (Apple's audit API for XCUITest)
  • Xcode 15, Swift 5.9

On this page