Table Basic

Basic Example

For basic styling—light padding and only horizontal dividers—add the base class .table to any <table>.

Dark Table

You can also invert the colors—with light text on dark backgrounds—with .table-dark.

UserEmailStatusAction
imgMark
[email protected]Active
imgJacob
[email protected]Inactive
imgLarry
[email protected]Active

Table Head

Use one of two modifier classes to make <thead>s appear light or dark gray.

#First NameLast NameAction
1MarkOtto
2JacobThornton
3LarryDooley

Striped Rows

Use .table-striped to add zebra-striping to any table row within the <tbody>.

#First NameLast NameAction
1MarkOtto
2JacobThornton
3LarryDooley

Bordered Table

Add .table-bordered for borders on all sides of the table and cells.

#First NameLast NameAction
1MarkOtto
2JacobThornton
3LarryDooley

Borderless Table

Add .table-borderless for a table without borders.

#First NameLast NameAction
1MarkOtto
2JacobThornton
3LarryDooley

Table Border Color

Add .table-bordered & .border-* for colored borders on all sides of the table and cells.

#First NameLast NameAction
1MarkOtto
2JacobThornton
3LarryDooley

Table Border Color

Add .table-bordered & .border-* for colored borders on all sides of the table and cells.

#First NameLast NameAction
1MarkOtto
2JacobThornton
3LarryDooley

Vertical Alignment

Table cells in <tbody> inherit their alignment from <table> and are aligned to the the top by default. Use the vertical align classes to re-align where needed.

#First NameLast NameAction
1MarkOtto
2JacobThornton
3LarryDooley
4JacobThornton

Nesting

Border styles, active styles, and table variants are not inherited by nested tables.

#FirstLastHandle
1MarkOtto@mdo
HeaderHeaderHeader
AFirstLast
BFirstLast
3JacobThornton@fat

Hoverable Rows

Add .table-hover to enable a hover state on table rows within a <tbody>.

#First NameLast NameAction
1MarkOtto
2JacobThornton
3LarryDooley

Small Table

Add .table-sm to make tables more compact by cutting cell padding in half.

#First NameLast NameAction
1MarkOtto
2JacobThornton
3LarryDooley
4MarkOtto

Contextual Classes

Use contextual classes to color table rows or individual cells.

#Column headingColumn headingColumn heading
1Column contentColumn contentColumn content
2Column contentColumn contentColumn content
3Column contentColumn contentColumn content
4Column contentColumn contentColumn content
5Column contentColumn contentColumn content

Captions

A <caption> functions like a heading for a table. It helps users with screen readers to find a table and understand what it’s about and decide if they want to read it.

List of users
#First NameLast NameHandle
1MarkOtto@mdo
2JacobThornton@fat
3LarryDooley@twitter

Responsive Table

Create responsive tables by wrapping any .table in .table-responsive to make them scroll horizontally on small devices (under 768px).

#Invoice NoCustomerDateAmountPayment ModeStatusAction
1
#INV368967
img
Laura Biding
13 May 2025$950
Cash on Delivery
Pending
2
#INV368967
img
Justin Gaethje
13 May 2025$950
Online Payment
Cancelled
3
#INV368967
img
Simon Cohen
13 May 2025$950
Cheque
Completed