ARIA Structure Roles

ARIA role: caption

A visible label or explanatory caption associated with tabular or illustrated content. Prefer caption for a table and figcaption for a figure; keep the caption in its proper context. The example demonstrates a native equivalent or preferred alternative and deliberately omits redundant ARIA. Explicit roles do not implement visual presentation, interaction or focus management; verify allowed role/element combinations in ARIA in HTML. Accessibility exposure varies with browser, platform and assistive technology. Test relevant combinations; rendering is not proof of accessibility.

Formal Syntax & Structure

html syntaxhtml
role="caption"

Parameters & Attributes

NameTypeDescription
roletokenExplicit role token caption; use only where allowed. Omit when native semantics match.

Working Example

Example Snippethtml
<table>  <caption>Stock</caption>  <tr>    <th>Item</th>    <th>Count</th>  </tr>  <tr>    <td>Pens</td>    <td>4</td>  </tr></table>
HTML Reference