Table icon
Table icon
Table icon

Table

A table is a structured layout for organizing and displaying information in rows and columns. Tables make it easier to compare data, spot patterns, and perform actions on multiple items at once. Each row typically represents a single entity (e.g., user, product, transaction), and columns define attributes or data points related to that entity.

Usage

Tabular Data Representation: When information can be meaningfully broken down into columns (attributes) and rows (entities).

Sortable/Filterable Views: Users can find, compare, or manage data (e.g., sorting by date, filtering by status).

Bulk Operations: Tables often feature checkboxes or selection tools for batch actions (e.g., deleting multiple rows at once).

Use cases

  • Displaying inventory, product listings, or order history

  • Data dashboards or analytics reports

  • User directories, logs, or audit trails

Not to be confused with

List: A list usually displays items in a simpler, one-dimensional vertical format, often with a few attributes or inline actions. Tables are more structured, with multiple columns and possibly more advanced features (sorting, filtering).

Cards: Cards group related content in a free-form container. Tables impose a strict grid framework, which is ideal for comparing similar data fields across multiple entries.

Best practices

Meaningful Columns & Headers

  • Use clear, descriptive header labels so users understand each column’s purpose.

  • Consider adding tooltips or helper text if a column title needs clarification.

Sortable & Filterable

  • Offer sorting by relevant columns (e.g., name, date, status).

  • Provide filtering or search functions for large datasets to help users narrow results.

Responsive & Scrolling

  • On smaller screens, tables can become unwieldy. Consider responsive patterns like horizontal scrolling or reflowing columns into a stacked layout.

  • Ensure columns don’t become too narrow to read, or text will truncate excessively.

Highlight Interactivity

  • Show hover or focus states if a row or cell is clickable (e.g., editing a row, viewing details).

  • Provide checkboxes or selection indicators for multi-select actions.

Accessible Markup

  • Use semantic HTML (e.g., <table>, <thead>, <tbody>, <th>, <td>) to help screen readers interpret data correctly.

  • Add scope="col" or scope="row" and possibly aria-describedby or aria-label for clarity.

  • Ensure keyboard navigation allows moving across rows/columns properly.

Formatting Data

  • Align text appropriately (e.g., right-align numeric or currency data for easy scanning).

  • Use consistent formatting for dates, currency, or percentages.

  • Highlight key values with bold or color if it helps users parse data faster.

Minimize Clutter

  • Only show relevant columns—excessive columns can overwhelm users.

  • Group or collapse advanced columns if the table contains optional or less frequently used data.

Clear Empty States & Errors

  • Show a message when no data is available or when a filter returns zero results.

  • Gracefully handle loading states (e.g., skeleton rows) if data is being fetched asynchronously.

If your data is not naturally row-column oriented, consider a list or card layout instead.

Summary

A table is ideal for displaying structured data in a way that’s easy to compare and act upon. By defining meaningful columns, offering sorting and filtering options, and ensuring responsive, accessible markup, tables can handle everything from basic item lists to complex datasets. Thoughtful design—such as minimizing clutter, providing interactive cues, and following consistent formatting—ensures that users can swiftly navigate, analyze, and manipulate tabular information.

In action

Also in Data