Data table

A data table displays structured information in rows and columns, allowing users to scan, compare, sort, and act on multiple items simultaneously. Table design directly affects how quickly users can find and process information.

What is a data table in UX design?

A data table is a UI component that presents structured data in a grid of rows and columns, where each row represents a single record and each column represents an attribute of that record. Data tables are used in admin interfaces, analytics dashboards, financial tools, inventory systems, and any product where users need to view, compare, sort, filter, or act on collections of structured data. The design of a data table directly determines how efficiently users can find specific information and take action on it.

How to design an effective data table?

Column headers should clearly describe the data in each column and support sorting where the column content is sortable. Left-align text columns and right-align numeric columns to support scanning and comparison. Use consistent column widths where possible but allow text to wrap rather than truncate critical information. Provide adequate row height so content is readable without being wasteful of vertical space. Alternate row backgrounds or use sufficient spacing between rows to help users track horizontally across wide tables. Pin important columns like identifiers and actions when horizontal scrolling is required.

What interactions should data tables support?

Sorting by column allows users to reorder the dataset to find outliers, identify patterns, or locate specific values. Filtering reduces the visible rows to those matching selected criteria. Pagination or infinite scroll manages large datasets. Row selection enables bulk actions on multiple items simultaneously. Inline editing allows users to update values without navigating to a detail view. Actions per row, typically in a final column or revealed on hover, give users quick access to the most common operations for each record.

How to make data tables accessible?

Tables must use semantic HTML table markup with proper thead, tbody, th, and td elements so screen readers can announce column headers when reading cell content. Complex tables with multiple header levels require scope attributes or ARIA to establish relationships between headers and cells. Sortable columns must communicate their current sort state via aria-sort. Row checkboxes must be properly labeled. Keyboard navigation must allow users to move between cells, activate sort controls, and trigger row actions without a mouse. See the accessible forms guide for related accessibility principles.

Related terms

Related guides