< Back to Guides | Learn more at PaulJAdam.com >

Tables - Accessibility Quick Guide

Requirements

Simple Data Table

  1. Title of data table is inside the <caption> element.
  2. Column headers are inside <th scope="col"> elements.
  3. Row headers are inside <th scope="row"> elements.
  4. Avoid using blank header cells.
  5. Header cells with text abbreviations that need expansion use the title attribute with the expanded text set as the value.

Complex Data Table

  1. Title of data table is inside the <caption> element.
  2. Column headers are inside <th scope="col"> elements.
  3. Column headers that span more than one column include a colspan attribute with the number of columns spanned as the value and scope="colgroup".
  4. Row headers are inside <th scope="row"> elements.
  5. Row headers that span more than one row include a rowspan attribute with the number of rows spanned as the value and scope="rowgroup".
  6. Avoid using blank header cells.
  7. Header cells with text abbreviations that need expansion use the title attribute with the expanded text set as the value.
  8. Headers attribute may not be necessary if table header rowspan and colspan is sufficient.

Sortable Data Table

  1. Sortable table header cells use the aria-sort attribute with correct value.
  2. Sortable header cells are keyboard focusable and operable.

Good Example

Simple Data Table

Table 13.1
2018 Single Filer Taxable Income Tax Brackets and Rates
RateTaxable Income BracketTax Owed
10% $0 to $9,525 10% of taxable income
12% $9,526 to $38,700 $952.50 plus 12% of the amount over $9525
22% $38,701 to $82,500 $4,453.50 plus 22% of the amount over $38,700
24% $82,501 to $157,500 $14,089.50 plus 24% of the amount over $82,500
32% $157,501 to $200,000 $32,089.50 plus 32% of the amount over $157,500
35% $200,001 to $500,000 $45,689.50 plus 35% of the amount over $200,000
37% $ 500 , 001 + $150,689.50 plus 37% of the amount over $500,000

Complex Data Table

SHOPMART, INC.
Comparative Balance Sheet
December 31, 2018 and 2017
ItemSub-ItemSub-Item20182017Increase
(Decrease)
AssetsCurrent Assets:Cash$22,000$42,000$(20,000)
Accounts Receivable$90,000$73,000$17,000
Merchandise Inventory$143,000$145,000$(2,000)
Long-term Assets:Plant Assets$507,000$252,000$255,000
Accumulated Depreciation--Plan Assets$(47,000)$(42,000)$(5,000)
Total Assets:$715,000$470,000$245,000
LiabilitiesCurrent Liabilities:Accounts Payable$90,000$50,000$40,000
Accrued Liabilities$5,000$10,000$(5,000)
Long-term Liabilities:Notes Payable$160,000$80,000$80,000
Total Liabilities$255,000$140,000$115,000
Stockholder's EquityCommon Stock, no par$370,000$250,000$120,000
Retained Earnings$110,000$80,000$30,000
Treasury Stock$(20,000)$0$(20,000)
Total Stockholder's Equity$460,000$330,000$130,000
Total Liabilities and Stockholder's Equity$715,000$470,000$245,000