Skip to main content
Accessibility

Browser Accessibility API Mapping

Browser Accessibility API Mapping is the process by which web browsers translate HTML elements, attributes, and ARIA annotations into structured data exposed through platform-specific accessibility APIs, enabling assistive technologies like screen readers to understand and interact with web content.
  • accessibility API
  • browser internals
  • platform mapping
  • assistive technology
  • interoperability

When a browser parses an HTML document, it builds the DOM (Document Object Model) and a parallel structure known as the accessibility tree. Browser Accessibility API Mapping is the bridge between that accessibility tree and the platform-level accessibility APIs — such as Microsoft UI Automation (UIA) on Windows, NSAccessibility on macOS, and ATK/AT-SPI on Linux. These mappings define exactly how each HTML element, ARIA role, state, and property translates into objects, roles, names, descriptions, and relationships that assistive technologies can query.

The W3C maintains formal specifications for these mappings, including the HTML Accessibility API Mappings (HTML-AAM), ARIA Accessibility API Mappings (ARIA-AAM), and Accname (Accessible Name and Description Computation) specifications. Together, these documents ensure that browser vendors implement consistent behavior, so a <button> element in Chrome on Windows exposes the same semantic meaning as a <button> in Firefox on macOS. Without these standardized mappings, assistive technology users would face wildly inconsistent experiences across browsers and operating systems.

Why Browser Accessibility API Mapping matters

Browser Accessibility API Mapping sits at the very heart of web accessibility. It is the mechanism that makes semantic HTML and ARIA actually useful to people who rely on assistive technologies. Here's why it matters:

  • Screen reader users depend on the mapped roles, states, and names to understand what each element is and how to interact with it. A <nav> element is mapped to a navigation landmark role, letting users jump directly to site navigation.
  • Voice control users issue commands like "click submit button" — the word "button" works because the browser mapped the element's role correctly.
  • Developers need to understand these mappings to write markup that produces the correct accessibility tree output. Misusing ARIA or choosing non-semantic elements can lead to incorrect or missing mappings, breaking the experience for assistive technology users.
  • Automated validation tools check whether your HTML and ARIA usage will produce valid mappings. Issues like conflicting roles, missing accessible names, or prohibited ARIA attributes are flagged because they result in broken or ambiguous API mappings.

When mappings go wrong — for example, when a <div> is styled to look like a button but lacks a role="button" and keyboard handling — the accessibility API receives no button role. The screen reader announces it as generic text, and keyboard users cannot activate it. The visual appearance is irrelevant; only the mapped semantics reach assistive technologies.

How Browser Accessibility API Mapping works

From HTML to the accessibility tree

The browser reads each HTML element and applies mapping rules from the HTML-AAM specification. Native HTML elements carry implicit roles and properties:

  • <a href="..."> maps to the link role
  • <input type="checkbox"> maps to the checkbox role with a checked state
  • <h1> through <h6> map to heading roles with corresponding level properties
  • <main> maps to the main landmark role

These implicit mappings are one of the strongest reasons to use semantic HTML: the browser does the heavy lifting automatically.

ARIA overrides and supplements

When native HTML semantics are insufficient, ARIA attributes modify or supplement the mappings. The browser applies ARIA-AAM rules to translate role, aria-* states, and aria-* properties into their API equivalents. ARIA roles override the element's implicit role, while ARIA states and properties add or modify exposed attributes.

Accessible name computation

Each accessibility API object needs a human-readable name. The Accname specification defines the algorithm browsers use to compute this name, drawing from aria-labelledby, aria-label, <label> associations, alt text, element content, title attributes, and other sources in a specific priority order.

Platform API exposure

Finally, the browser exposes the resulting accessibility tree objects through the operating system's accessibility API. A screen reader like NVDA queries UIA on Windows, while VoiceOver queries NSAccessibility on macOS. Each platform API has its own object model, so the browser translates the abstract accessibility tree into platform-specific structures.

Code examples

Bad example: broken mapping due to non-semantic markup

<div class="btn" onclick="submitForm()">
  Submit
</div>

This <div> maps to a generic group with no role, no keyboard focusability, and no button semantics. The accessibility API exposes it as static text — screen readers won't announce it as a button, and keyboard users can't reach or activate it.

Good example: correct mapping with semantic HTML

<button type="submit">
  Submit
</button>

The <button> element automatically maps to the button role in the accessibility API. It is keyboard-focusable, activatable with Enter or Space, and its text content ("Submit") is computed as the accessible name. No ARIA needed.

Bad example: conflicting ARIA disrupts mapping

<nav role="button" aria-label="Main navigation">
  <ul>
    <li><a href="/home">Home</a></li>
    <li><a href="/about">About</a></li>
  </ul>
</nav>

Applying role="button" to a <nav> element overrides its implicit navigation landmark role. The browser now maps it as a button, hiding the navigation semantics from assistive technologies. This is a mapping conflict that validation tools will flag.

Good example: proper landmark with accessible name

<nav aria-label="Main navigation">
  <ul>
    <li><a href="/home">Home</a></li>
    <li><a href="/about">About</a></li>
  </ul>
</nav>

The <nav> element maps to the navigation landmark role, and aria-label provides its accessible name. Screen reader users can identify and jump to "Main navigation" effortlessly.

Good example: ARIA supplementing a custom widget

<div role="tablist" aria-label="Product information">
  <button role="tab" aria-selected="true" aria-controls="panel-details" id="tab-details">
    Details
  </button>
  <button role="tab" aria-selected="false" aria-controls="panel-reviews" id="tab-reviews">
    Reviews
  </button>
</div>
<div role="tabpanel" id="panel-details" aria-labelledby="tab-details">
  <p>Product details go here.</p>
</div>
<div role="tabpanel" id="panel-reviews" aria-labelledby="tab-reviews" hidden>
  <p>Customer reviews go here.</p>
</div>

Here ARIA roles and properties create proper tab interface mappings. The browser exposes tablist, tab, and tabpanel roles with their selection states and relationships, giving screen readers a complete picture of the widget's structure and current state.

Understanding Browser Accessibility API Mapping empowers you to write markup that reliably communicates meaning to every user, regardless of the browser, operating system, or assistive technology they use. When you choose semantic HTML first and apply ARIA intentionally, you work with the mapping specifications rather than against them — and the accessibility tree reflects exactly what you intended.

Help us improve this glossary term

Was this guide helpful?

Scan your site

Rocket Validator scans thousands of pages in seconds, detecting accessibility and HTML issues across your entire site.

🌍 Trusted by teams worldwide

Validate at scale.
Ship accessible websites, faster.

Automated HTML & accessibility validation for large sites. Check thousands of pages against WCAG guidelines and W3C standards in minutes, not days.

Scheduled Reports
API Access
Open Source Standards
$7 / 7 days

Pro Trial

Full Pro access. Cancel anytime.

Start Pro Trial →

Join teams across 40+ countries