Skip to content
easeweb
Search topics

Tables with a title but no caption

Each table's title is a paragraph above it or a row inside it, not a caption, so a screen reader that jumps to the table hears no name and can't tell it from the one beside it.

WCAG 2.2
SC 1.3.1A
Required by
Section 508 · EN 301 549 (EU)
Broken <p class="table-title">
The accessibility problem illustrated: No vision:Standard or express?
01

The problem

Screen reader users who jump from table to table hear no title, so they can't tell which table they are in.

02

Try it

Press Tab to jump from table to table.

Each Tab stands in for a screen reader’s key for the next table (T in NVDA and JAWS). The panel shows what it says as it arrives. Can you tell which table you are in? In Broken 2, count the rows it gives.

Broken Can you fix this?

Standard delivery

WeightPrice
Up to 1 kg$4
1 to 5 kg$7

Express delivery

WeightPrice
Up to 1 kg$9
1 to 5 kg$15

Screen reader says:

(Tab to a table)

A recreated demo. The broken version is intentionally inaccessible.

03

The fix

Make each table's visible title its name: a caption, or aria-labelledby to the title.

  1. 1Put a data table's visible title in its caption, or point the table's aria-labelledby at it.
  2. 2Never draw a title as a row of the table's cells.
  3. 3Give every table a name that tells it apart from the others on the page.
Before

The title in a paragraph above the table

<p class="table-title">Express delivery</p><table class="rates">  <thead>    <tr>      <th scope="col">Weight</th>      <th scope="col">Price</th>    </tr>  </thead>  <tbody>    <tr>      <th scope="row">Up to 1 kg</th>      <td>$9</td>    </tr>    <tr>      <th scope="row">1 to 5 kg</th>      <td>$15</td>    </tr>  </tbody></table>
After

A caption

<table class="rates">  <caption>Express delivery</caption>  <thead>    <tr>      <th scope="col">Weight</th>      <th scope="col">Price</th>    </tr>  </thead>  <tbody>    <tr>      <th scope="row">Up to 1 kg</th>      <td>$9</td>    </tr>    <tr>      <th scope="row">1 to 5 kg</th>      <td>$15</td>    </tr>  </tbody></table>

Why this fix: Use native HTML first

Fixing this with an AI coding assistant? Get this guide as Markdown, or get every guide in your coding agent.

04

Verify the fix

5 checks, no mouse.

Test with: Screen reader, Keyboard, Zoom

0 of 5 checked

Record the OS, browser and assistive-technology versions, the build, the date, and the actual result of each step. Repeat after the table component changes.

Limits

This is a starting pattern, not a guarantee for every table. Screen readers differ in when they read a caption and how they word a table's size, and not all of them list tables. A name only helps when it says what is in the table: two tables captioned "Prices" are as hard to tell apart as two with no caption.

This is a recreated teaching example, not a finding about a named client. The code is a starting pattern: test it in your own product. No completed assistive-technology test is claimed here.

Keep this fixed as your code changes.

Turn guides like this into rules your coding agents and CI follow, then have the result retested with a keyboard and screen readers.

How retests work