A card is a flexible and extensible content container. It includes options for headers and footers, a wide variety of content, contextual background colors, and powerful display options.
Below is an example of a basic card with mixed content and a fixed width.
Cards have no fixed width to start, so they'll naturally fill the full width of its parent element.
Card title
Some quick example text to build on the card title and make up the bulk of the card's content.
<Card Style="width:18rem;">
<CardBody>
<CardTitle>Card title</CardTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
<Button Color="ButtonColor.Primary" To="#" Type="ButtonType.Link">Go somewhere</Button>
</CardBody>
</Card>
<Card Style="width:18rem;">
<CardBody>
<CardTitle>Card title</CardTitle>
<CardSubTitle Class="mb-2 text-muted">Card subtitle</CardSubTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
<CardLink To="#">Card link</CardLink>
<CardLink To="#">Another link</CardLink>
</CardBody>
</Card>
<Card Class="mb-4" Style="width:18rem;">
<img class="rounded-top" src="/images/placeholder.png" alt="placeholder" />
<CardBody>
<CardTitle>Card title</CardTitle>
<CardSubTitle Class="mb-2 text-muted">Card subtitle</CardSubTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
<Button Color="ButtonColor.Primary" To="#" Type="ButtonType.Link">Go somewhere</Button>
</CardBody>
</Card>
<Card Style="width:18rem;">
<CardBody>
<CardTitle>Card title</CardTitle>
<CardSubTitle Class="mb-2 text-muted">Card subtitle</CardSubTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
<Button Color="ButtonColor.Primary" To="#" Type="ButtonType.Link">Go somewhere</Button>
</CardBody>
<img class="rounded-bottom" src="/images/placeholder.png" alt="placeholder" />
</Card>
Mix and match multiple content types to create the card you need, or throw everything in there.
Shown below are image styles, blocks, text styles, and a list group—all wrapped in a fixed-width card.
Card title
Some quick example text to build on the card title and make up the bulk of the card's content.
<Card Style="width:18rem;">
<img class="rounded-top" src="/images/placeholder.png" alt="placeholder" />
<CardBody>
<CardTitle>Card title</CardTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
</CardBody>
<ul class="list-group list-group-flush">
<li class="list-group-item">An item</li>
<li class="list-group-item">A second item</li>
<li class="list-group-item">A third item</li>
</ul>
<CardBody>
<CardLink To="#">Card link</CardLink>
<CardLink To="#">Another link</CardLink>
</CardBody>
</Card>
<Card Style="width:18rem;">
<CardHeader>
Featured
</CardHeader>
<CardBody>
<CardTitle>Special title treatment</CardTitle>
<CardText>With supporting text below as a natural lead-in to additional content.</CardText>
<Button Color="ButtonColor.Primary" To="#" Type="ButtonType.Link">Go somewhere</Button>
</CardBody>
</Card>
Cards assume no specific width to start, so they’ll be 100% wide unless otherwise stated.
You can change this as needed with custom CSS, grid classes, grid Sass mixins, or utilities.
Special title treatment
With supporting text below as a natural lead-in to additional content.
Some quick example text to build on the card title and make up the bulk of the card's content.
Header
Secondary card title
Some quick example text to build on the card title and make up the bulk of the card's content.
Header
Success card title
Some quick example text to build on the card title and make up the bulk of the card's content.
Header
Danger card title
Some quick example text to build on the card title and make up the bulk of the card's content.
Header
Warning card title
Some quick example text to build on the card title and make up the bulk of the card's content.
Header
Info card title
Some quick example text to build on the card title and make up the bulk of the card's content.
Header
Light card title
Some quick example text to build on the card title and make up the bulk of the card's content.
Header
Dark card title
Some quick example text to build on the card title and make up the bulk of the card's content.
<Card Color="CardColor.Primary" Class="mb-4" Style="width:18rem;">
<CardHeader>Header</CardHeader>
<CardBody>
<CardTitle>Primary card title</CardTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
</CardBody>
</Card>
<Card Color="CardColor.Secondary" Class="mb-4" Style="width:18rem;">
<CardHeader>Header</CardHeader>
<CardBody>
<CardTitle>Secondary card title</CardTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
</CardBody>
</Card>
<Card Color="CardColor.Success" Class="mb-4" Style="width:18rem;">
<CardHeader>Header</CardHeader>
<CardBody>
<CardTitle>Success card title</CardTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
</CardBody>
</Card>
<Card Color="CardColor.Danger" Class="mb-4" Style="width:18rem;">
<CardHeader>Header</CardHeader>
<CardBody>
<CardTitle>Danger card title</CardTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
</CardBody>
</Card>
<Card Color="CardColor.Warning" Class="mb-4" Style="width:18rem;">
<CardHeader>Header</CardHeader>
<CardBody>
<CardTitle>Warning card title</CardTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
</CardBody>
</Card>
<Card Color="CardColor.Info" Class="mb-4" Style="width:18rem;">
<CardHeader>Header</CardHeader>
<CardBody>
<CardTitle>Info card title</CardTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
</CardBody>
</Card>
<Card Color="CardColor.Light" Class="mb-4" Style="width:18rem;">
<CardHeader>Header</CardHeader>
<CardBody>
<CardTitle>Light card title</CardTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
</CardBody>
</Card>
<Card Color="CardColor.Dark" Class="mb-4" Style="width:18rem;">
<CardHeader>Header</CardHeader>
<CardBody>
<CardTitle>Dark card title</CardTitle>
<CardText>Some quick example text to build on the card title and make up the bulk of the card's content.</CardText>
</CardBody>
</Card>
Use card groups to render cards as a single, attached element with equal width and height columns.
Card groups start off stacked and use display: flex; to become attached with uniform dimensions starting at the sm breakpoint.
Card title
This is a wider card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
Last updated 3 mins ago
Card title
This card has supporting text below as a natural lead-in to additional content.
Last updated 3 mins ago
Card title
This is a wider card with supporting text below as a natural lead-in to additional content. This card has even longer content than the first to show that equal height action.
Last updated 3 mins ago
<CardGroup>
<Card Class="mb-4" Style="width:18rem;">
<img src="/images/placeholder.png" alt="placeholder" />
<CardBody>
<CardTitle>Card title</CardTitle>
<CardText>This is a wider card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.</CardText>
<CardText Class="text-muted">Last updated 3 mins ago</CardText>
</CardBody>
</Card>
<Card Class="mb-4" Style="width:18rem;">
<img src="/images/placeholder.png" alt="placeholder" />
<CardBody>
<CardTitle>Card title</CardTitle>
<CardText>This card has supporting text below as a natural lead-in to additional content.</CardText>
<CardText Class="text-muted">Last updated 3 mins ago</CardText>
</CardBody>
</Card>
<Card Class="mb-4" Style="width:18rem;">
<img src="/images/placeholder.png" alt="placeholder" />
<CardBody>
<CardTitle>Card title</CardTitle>
<CardText>This is a wider card with supporting text below as a natural lead-in to additional content. This card has even longer content than the first to show that equal height action.</CardText>
<CardText Class="text-muted">Last updated 3 mins ago</CardText>
</CardBody>
</Card>
</CardGroup>
When using card groups with footers, their content will automatically line up.
Card title
This is a wider card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
Last updated 3 mins ago
Card title
This card has supporting text below as a natural lead-in to additional content.
Last updated 3 mins ago
Card title
This is a wider card with supporting text below as a natural lead-in to additional content. This card has even longer content than the first to show that equal height action.
Last updated 3 mins ago
<CardGroup>
<Card Class="mb-4" Style="width:18rem;">
<img src="/images/placeholder.png" alt="placeholder" />
<CardBody>
<CardTitle>Card title</CardTitle>
<CardText>This is a wider card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.</CardText>
</CardBody>
<CardFooter>
<small class="text-muted">Last updated 3 mins ago</small>
</CardFooter>
</Card>
<Card Class="mb-4" Style="width:18rem;">
<img src="/images/placeholder.png" alt="placeholder" />
<CardBody>
<CardTitle>Card title</CardTitle>
<CardText>This card has supporting text below as a natural lead-in to additional content.</CardText>
</CardBody>
<CardFooter>
<small class="text-muted">Last updated 3 mins ago</small>
</CardFooter>
</Card>
<Card Class="mb-4" Style="width:18rem;">
<img src="/images/placeholder.png" alt="placeholder" />
<CardBody>
<CardTitle>Card title</CardTitle>
<CardText>This is a wider card with supporting text below as a natural lead-in to additional content. This card has even longer content than the first to show that equal height action.</CardText>
</CardBody>
<CardFooter>
<small class="text-muted">Last updated 3 mins ago</small>
</CardFooter>
</Card>
</CardGroup>