Bootstrap 5 Basic
Bootstrap 5 Flexbox
Bootstrap 5 offers a wide range of color utilities that allow you to style text, backgrounds, borders, and components. These colors are consistent across components, ensuring a uniform look throughout your site.
.text-primary
, .text-secondary
, .text-success
, .text-danger
, .text-warning
, .text-info
, .text-light
, .text-dark
, .text-muted
, .text-white
Try it yourself
Background color utilities help you style backgrounds using the same color scheme.
bg-primary
, bg-secondary
, bg-success
, bg-danger
, bg-warning
, bg-info
, bg-light
, bg-dark
, and bg-white
.Try it yourself
These classes combine both text color and background color to ensure better readability and contrast, making it easy to style text without needing separate text and background classes
text-bg-primary
, text-bg-secondary
, text-bg-success
, text-bg-danger
, text-bg-warning
, text-bg-info
, text-bg-light
, text-bg-dark
, and text-bg-white
.Try it yourself
These classes allow you to add colored borders to any element with minimal code
border-primary
, border-secondary
, border-success
, border-danger
, border-warning
, border-info
, border-light
, border-dark
, and border-white
.Try it yourself