How To Center A Column In Bootstrap - Code Helpers

Variations

By manipulating the number of the centered column you can set its width and also define on which screen size it should be stretched full width.

This column has .col-xl-4 .col-lg-12 classes which makes it 6 column width on the screen larger than 1200px but on smaller screens it will stretch full width. Resize the browser window to see the effect.

See Breakpoint Docs to learn more about available configurations.

.row .col-xl-4 .col-lg-12
  • HTML
<!--Grid row--> <div class="row d-flex justify-content-center"> <!--Grid column--> <div class="col-xl-4 col-lg-12"></div> <!--Grid column--> </div> <!--Grid row-->

Từ khóa » Html Col Center