HTML tables are semantically powerful but visually bland. Our Table components add consistent styling while preserving the native table structure - <table>, <thead>, <tbody>, <tr>, <th>, <td> - because screen readers depend on these elements for data navigation. For interactive features like sorting and filtering, see Data Table.
<Table> <TableCaption>A list of your recent invoices.</TableCaption> <TableHeader> <TableRow> <TableHeadclassName="w-[100px]">Invoice</TableHead> <TableHead>Status</TableHead> <TableHead>Method</TableHead> <TableHeadclassName="text-right">Amount</TableHead> </TableRow> </TableHeader> <TableBody> <TableRow> <TableCellclassName="font-medium">INV001</TableCell> <TableCell>Paid</TableCell> <TableCell>Credit Card</TableCell> <TableCellclassName="text-right">$250.00</TableCell> </TableRow> </TableBody></Table>
Examples
Data Table
You can use the <Table /> component to build more complex data tables. Combine it with
TanStack Table to add sorting, filtering, and pagination.
See the Data Table documentation for a full guide.
You can also see data-table examples in the Blocks Library.
Component Composition
RTL Support
Set the direction once with DirectionProvider (or <html dir="rtl">) and the table follows it: cells align to the start side. No dir prop or rtl: classes needed.
Motion
Alpha: Motion Compositions
Motion components work standalone, but some compositions may behave unexpectedly: this is still under active development. If you find a broken composition, please file an issue.
Use MotionTable and MotionTableRow for staggered entrance animations powered by motion. The table uses a scaleIn entrance (fade, scale, and blur) with a bouncy spring transition, and each row staggers by 50ms via the index prop.
Requires the motion package. Use MotionTable instead of Table and MotionTableRow instead of TableRow. All other sub-components stay the same. The regular components are perfectly fine - this is an optional enhancement.
API Reference
Table
Prop
Type
Default
Description
dir
'ltr' | 'rtl'
-
Text direction override. Resolved via useDirection (dir prop -> DirectionProvider -> <html dir>).