Grid Template examples
Idea React grid examples
Basic grid layouts to get you familiar with building within the Bootstrap grid system.
These examples use a page-local style module to distinguish the columns.
Six grid tiers
There are six tiers to the Bootstrap grid system, one for each range of devices we support. Each tier starts at a minimum viewport size and automatically applies to the larger devices unless overridden.
Three equal columns
Get three equal-width columns starting at desktops and scaling to large desktops. On mobile devices, tablets and below, the columns will automatically stack.
Three equal columns alternative
Set the number of columns on Row to create an evenly divided grid.
Three unequal columns
Get three columns starting at desktops and scaling to large desktops of various widths. Remember, grid columns should add up to twelve for a single horizontal block. More than that, and columns start stacking no matter the viewport.
Two columns
Get two columns starting at desktops and scaling to large desktops.
Full width, single column
A column defaults to full width when no responsive span is set.
Two columns with two nested columns
Per the documentation, nesting is easy—just put a row of columns within an existing column. This gives you two columns starting at desktops and scaling to large desktops, with another two (equal widths) within the larger column.
At mobile device sizes, tablets and down, these columns and their nested columns will stack.
8 columns from md
Mixed: mobile and desktop
The grid has six responsive tiers: xs (extra small), sm (small), md (medium), lg (large), xl (extra large), and 2xl (extra extra large). Combine the matching props on Col to create flexible layouts.
Each tier scales up, so a md prop also applies at larger breakpoints unless overridden.
Mixed: mobile, tablet, and desktop
Gutters
Set horizontal gutter utilities in Row's className.
className="gx-4" on the rowclassName="gx-4" on the rowclassName="gx-4" on the rowclassName="gx-4" on the rowclassName="gx-4" on the rowclassName="gx-4" on the rowSet vertical gutter utilities in Row's className.
className="gy-4" on the rowclassName="gy-4" on the rowclassName="gy-4" on the rowclassName="gy-4" on the rowclassName="gy-4" on the rowclassName="gy-4" on the rowSet both horizontal and vertical gutter utilities in Row's
className.
className="g-3" on the rowclassName="g-3" on the rowclassName="g-3" on the rowclassName="g-3" on the rowclassName="g-3" on the rowclassName="g-3" on the row