Favorites

HTML aria-rowcount ARIA Attribute

aria-rowcount
ARIA AttributeThis ARIA attribute is supported by all modern browsers.
Updated 28th November 2026

The aria-rowcount attribute gives the total number of rows in a table or grid when only some of the rows are present in the DOM.

☕
Enjoying this site?

Help keep it running with a small coffee donation. Every bit of support is appreciated!

Buy us a coffee

Description

The aria-rowcount attribute defines the total number of rows in a table, grid or treegrid. It is only needed when some rows are missing from the DOM, for example in a large data table that uses paging or "virtual scrolling" to render just the visible rows. Screen readers can then announce the real size, such as "table with 500 rows".

Put it on the element with the table, grid or treegrid role, and give each row its position with aria-rowindex. The count includes header rows. Use -1 when the total is not known.

When every row is in the DOM, leave the attribute out and let the browser count them.

Properties

Type
Widget
Value
integer
Default
None
Used with
grid, table, treegrid

Syntax

<element role="table" aria-rowcount="number">

Values

  • integerThe total number of rows, or -1 if the total is unknown.

Example

<table aria-rowcount="501" aria-label="Orders">
<tr aria-rowindex="1"><th>Order</th><th>Total</th></tr>
<tr aria-rowindex="41"><td>#1040</td><td>$25</td></tr>
<tr aria-rowindex="42"><td>#1041</td><td>$18</td></tr>
</table>

Browser Support

The following information will show you the current browser support for the aria-rowcount ARIA attribute. Hover over a browser icon to see the version that first introduced support for this ARIA attribute.

This ARIA attribute is supported by all modern browsers.

Desktop

Chrome
Edge
Firefox
Opera
Safari

Tablets & Mobile

Chrome Android
Firefox Android
Opera Android
Safari iOS
Samsung Internet
Android WebView
-
Supported Unknown Not supported
☕
Enjoying this site?

Help keep it running with a small coffee donation. Every bit of support is appreciated!

Buy us a coffee