Skip to content
Back to blog
Design Systems4 minute read

Keyboard-First Navigation for Complex Tables

Making dense data grids usable without a mouse: roving focus, predictable shortcuts and visible focus rings.

ASRaka Mahendra
  • Design Systems
  • Accessibility
  • Keyboard
  • UX
Cover art for “Keyboard-First Navigation for Complex Tables”

Dense tables are where keyboard support usually gives up. Hundreds of focusable cells make tabbing useless, so teams add a single tab stop and call it done. A roving tabindex gives you both: one tab stop for the grid and arrow keys to move inside it.

One tab stop, many cells

Only the active cell has tabindex="0"; the rest are -1. Arrow keys move the active cell and update the tabindex. Tab enters the grid once and leaves it once, which keeps the page navigation predictable.

function moveTo(row: number, col: number) {
  cells.forEach((cell) => cell.setAttribute('tabindex', '-1'));
  const next = cellsAt(row, col);
  next?.setAttribute('tabindex', '0');
  next?.focus();
}

Keep shortcuts understandable

Use Enter to open a row, Space to toggle a selection, Escape to close any overlay. Avoid clever single-letter shortcuts unless they are discoverable in a help panel. Consistency with other grids in the product matters more than novelty.

Show focus without shouting

A focus ring must be visible on the darkest and lightest rows. Prefer a two-tone outline — a light inner line and a dark outer line — so it survives every background. Never remove the outline without replacing it.

Announce changes

When a filter reduces a table from 200 rows to 3, a screen reader user needs to know. Keep a live region with the visible count and the active sort order. The visual table already communicates this; the accessible layer has to as well.

Copied