Bootstrap Home

Grids

Three Equal Width Columns

Resize screen to display three equal-width columns, on all devices and screen widths.


.col
.col
.col

Four Equal Width Columns

Resize screen to display four equal-width columns, on all devices and screen widths.


.col
.col
.col
.col

Setting One Column Width

Auto-layout for flexbox grid columns also means you can set the width of one column and have the sibling columns automatically resize around it.


1 of 3
2 of 3 (wider)
3 of 3



1 of 3
2 of 3 (wider)
3 of 3

Variable Width Content

Use col-{breakpoint}-auto classes to size columns based on the natural width of their content.


1 of 3
Variable width content
3 of 3



1 of 3
Variable width content
3 of 3

Responsive Columns

Resize the browser window to see the effect.

The columns will automatically stack on top of each other when the screen is less than 576px wide.


.col
.col
.col
.col

Two Unequal Responsive Columns

Resize the browser window to see the effect.

The columns will automatically stack on top of each other when the screen is less than 576px wide.


.col
.col



Stacked To Horizontal

Using a single set of col-sm-* classes, you can create a basic grid system that starts out stacked and becomes horizontal at the small breakpoint (sm).


col-sm-8
col-sm-4



col-sm
col-sm
col-sm

Mix And Match

To have columns not simply stack in some grid tiers, use a combination of different classes for each tier as needed.


.col-md-8
.col-6 .col-md-4



.col-6 .col-md-4
.col-6 .col-md-4
.col-6 .col-md-4



.col-6
.col-6



Row Columns

Use the responsive .row-cols-* classes to quickly set the number of columns that best render your content and layout.


Two Columns Across - Four Columns Total

Column
Column
Column
Column



Three Columns Across - Four Columns Total

Column
Column
Column
Column



Four Columns Across - Four Columns Total

Column
Column
Column
Column



With .row-cols-auto you can give the columns their natural width.

Column
Column
Column
Column



Four Columns Across - Four Columns Total

Column
Column
Column
Column



Individual Columns Can Have Custom Widths

Column
Column
Column
Column