Cards
Bootstrap’s cards provide a flexible and extensible content container with multiple variants and options.
The examples compose Card with its body, title, text, image, header, footer, and group wrappers.
Use body, row, theme, subtle, and translucent props instead of adding component classes.
Cards are flexible and extensible content containers with support for headers and footers, a wide variety of content, contextual background colors, and additional display options. Cards have no fixed width to start, so they’ll naturally fill the width of their parent element, or slot into your grid columns.
Card title
Some quick example text to build on the card title and make up the bulk of the card’s content.
Go somewhere<Stack
className="max-w-100 overflow-auto p-2"
gap={3}
style={{
resize: 'horizontal'
}}
>
<Card
style={{
maxWidth: '320px'
}}
>
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<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
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
</Card>
</Stack>How it works
Cards are built with as little markup and styles as possible, but still manage to deliver a ton of control and customization.
-
Cards are flexbox containers, so align their contents with flexbox utilities through
classNameand arrange them withRowandCol. -
Cardhas no default padding. Add aCardBodychild, or setbodyonCardfor a simple padded card. This allows greater flexibility with the least amount of overhead. -
Cards have no
marginby default. Use margin utilities throughclassNameor set spacing withStack'sgapprop. -
Cards can contain text, images, lists, and other content components.
-
Choose semantic elements that fit the content. Use the
asprop onCardor its child components to render an appropriate element such assectionorarticle.
Content types
Body
The building block of a card is CardBody. Use it whenever you need a padded section within a card.
<Stack
className="overflow-auto"
gap={3}
>
<Card>
<CardBody>
This is some text within a card body.
</CardBody>
</Card>
</Stack>For simple cards, set the body prop directly on Card.
<Stack
className="overflow-auto"
gap={3}
>
<Card body>
This is some text within a card body.
</Card>
</Stack>Titles, text, and links
Card bodies arrange their direct children in a column and apply a consistent gap, so titles and text need no additional styles.
- Use
CardTitlefor a title,CardSubtitlefor a subtitle, andCardTextfor text.CardSubtitlereduces the gap above it.
Use text and color utilities through className as needed. A color utility on CardSubtitle overrides --bs-card-subtitle-color. Links need no card-specific wrapper.
Example card title
With a card subtitle
Some quick example text to build on the card title and make up the bulk of the card’s content.
Card link<Stack
className="overflow-auto"
gap={3}
>
<Card
style={{
maxWidth: '320px'
}}
>
<CardBody>
<CardTitle>
Example card title
</CardTitle>
<CardSubtitle className="fg-3">
With a 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>
<a href="#">
Card link
</a>
</CardBody>
</Card>
</Stack>Images
Place images anywhere in a card and style as you like.
Image within the body
Some quick example text to build on the card title and make up the bulk of the card’s content.
Last updated 3 mins ago<Stack
className="overflow-auto"
gap={3}
>
<Card
style={{
width: '18rem'
}}
>
<CardBody>
<CardImage
alt="Image cap"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<h5 className="mt-2 mb-0">
Image within the body
</h5>
<CardText className="fg-2">
Some quick example text to build on the card title and make up the bulk of the
card’s content.
</CardText>
<small className="fg-3">
Last updated 3 mins ago
</small>
</CardBody>
</Card>
</Stack>Set placement="top" or placement="bottom" on CardImage to round the corresponding image corners.
Some quick example text to build on the card title and make up the bulk of the card’s content.
Some quick example text to build on the card title and make up the bulk of the card’s content.
<div className="d-flex gap-3 flex-wrap overflow-auto">
<Card
style={{
width: '18rem'
}}
>
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<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
style={{
width: '18rem'
}}
>
<CardBody>
<CardText>
Some quick example text to build on the card title and make up the bulk of the
card’s content.
</CardText>
</CardBody>
<CardImage
alt="Image cap"
height="180"
placement="bottom"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
</Card>
</div>List groups
When your card only contains a list group—with no header, footer, or body—use ListGroup on its own. A card already draws an outer border, so a default list group inside a card would double that border.
- An item
- A second item
- A third item
<Stack
className="overflow-auto"
gap={3}
>
<ListGroup
style={{
width: '18rem'
}}
>
<ListGroupItem>
An item
</ListGroupItem>
<ListGroupItem>
A second item
</ListGroupItem>
<ListGroupItem>
A third item
</ListGroupItem>
</ListGroup>
</Stack>When you mix a list group with other card sub-components, set the flush prop on ListGroup to remove its outer border.
- An item
- A second item
- A third item
<Stack
className="overflow-auto"
gap={3}
>
<Card
style={{
width: '18rem'
}}
>
<CardHeader>
Featured
</CardHeader>
<ListGroup flush>
<ListGroupItem>
An item
</ListGroupItem>
<ListGroupItem>
A second item
</ListGroupItem>
<ListGroupItem>
A third item
</ListGroupItem>
</ListGroup>
</Card>
</Stack>- An item
- A second item
- A third item
<Stack
className="overflow-auto"
gap={3}
>
<Card
style={{
width: '18rem'
}}
>
<ListGroup flush>
<ListGroupItem>
An item
</ListGroupItem>
<ListGroupItem>
A second item
</ListGroupItem>
<ListGroupItem>
A third item
</ListGroupItem>
</ListGroup>
<CardFooter>
Card footer
</CardFooter>
</Card>
</Stack>Kitchen sink
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.
- An item
- A second item
- A third item
<Stack
className="overflow-auto"
gap={3}
>
<Card
style={{
width: '18rem'
}}
>
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<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>
<ListGroup flush>
<ListGroupItem>
An item
</ListGroupItem>
<ListGroupItem>
A second item
</ListGroupItem>
<ListGroupItem>
A third item
</ListGroupItem>
</ListGroup>
<CardBody className="flex-row gap-4">
<a href="#">
Card link
</a>
<a href="#">
Another link
</a>
</CardBody>
</Card>
</Stack>Header and footer
Add an optional header and/or footer within a card.
Special title treatment
With supporting text below as a natural lead-in to additional content.
Go somewhere<Stack
className="overflow-auto"
gap={3}
>
<Card>
<CardHeader>
Featured
</CardHeader>
<CardBody>
<CardTitle>
Special title treatment
</CardTitle>
<CardText>
With supporting text below as a natural lead-in to additional content.
</CardText>
<Button
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
</Card>
</Stack>Use CardHeader for a card header; set its as prop when the heading needs a specific semantic element.
Featured
Special title treatment
With supporting text below as a natural lead-in to additional content.
Go somewhere<Stack
className="overflow-auto"
gap={3}
>
<Card>
<CardHeader>
<h5 className="mb-0">
Featured
</h5>
</CardHeader>
<CardBody>
<CardTitle>
Special title treatment
</CardTitle>
<CardText>
With supporting text below as a natural lead-in to additional content.
</CardText>
<Button
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
</Card>
</Stack>A well-known quote, contained in a blockquote element.
Someone famous in Source Title
<Stack
className="overflow-auto"
gap={3}
>
<Card>
<CardHeader>
Quote
</CardHeader>
<CardBody>
<figure>
<blockquote className="fs-5 mb-3">
<p>
A well-known quote, contained in a blockquote element.
</p>
</blockquote>
<figcaption className="fg-3 fs-sm">
<p>
Someone famous in
<cite title="Source Title">
Source Title
</cite>
</p>
</figcaption>
</figure>
</CardBody>
</Card>
</Stack>Special title treatment
With supporting text below as a natural lead-in to additional content.
Go somewhere<Stack
className="overflow-auto"
gap={3}
>
<Card className="text-center">
<CardHeader>
Featured
</CardHeader>
<CardBody>
<CardTitle>
Special title treatment
</CardTitle>
<CardText>
With supporting text below as a natural lead-in to additional content.
</CardText>
<Button
className="mx-auto"
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
<CardFooter className="fg-2">
2 days ago
</CardFooter>
</Card>
</Stack>Width
Cards are 100% wide by default. Set their width with custom CSS, place them in Col components, or
pass sizing utilities through className.
Grid
Using the grid, wrap cards in columns and rows as needed.
<Stack
className="overflow-auto"
gap={3}
>
<Row>
<Col
className="mb-3 sm:mb-0"
sm={6}
>
<Card>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
With supporting text below as a natural lead-in to additional content.
</CardText>
<Button
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
</Card>
</Col>
<Col sm={6}>
<Card>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
With supporting text below as a natural lead-in to additional content.
</CardText>
<Button
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
</Card>
</Col>
</Row>
</Stack>Utilities
Use our handful of available sizing utilities to quickly set a card’s width.
<Stack
className="overflow-auto"
gap={3}
>
<Card className="w-75 mb-3">
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
With supporting text below as a natural lead-in to additional content.
</CardText>
<Button
href="#"
theme="primary"
variant="solid"
>
Button
</Button>
</CardBody>
</Card>
<Card className="w-50">
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
With supporting text below as a natural lead-in to additional content.
</CardText>
<Button
href="#"
theme="primary"
variant="solid"
>
Button
</Button>
</CardBody>
</Card>
</Stack>Custom CSS
Use custom CSS in your stylesheets or as inline styles to set a width.
<Stack
className="overflow-auto"
gap={3}
>
<Card
style={{
width: '18rem'
}}
>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
With supporting text below as a natural lead-in to additional content.
</CardText>
<Button
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
</Card>
</Stack>Navigation
Add some navigation to a card’s header (or block) with Bootstrap’s nav components.
Special title treatment
With supporting text below as a natural lead-in to additional content.
Go somewhere<Stack
className="overflow-auto"
gap={3}
>
<Card className="text-center">
<CardHeader>
<Nav
cardHeader
variant="tabs"
>
<NavLink
active
href="#"
>
Active
</NavLink>
<NavLink href="#">
Link
</NavLink>
<NavLink
aria-disabled="true"
disabled
>
Disabled
</NavLink>
</Nav>
</CardHeader>
<CardBody>
<CardTitle as="h5">
Special title treatment
</CardTitle>
<CardText>
With supporting text below as a natural lead-in to additional content.
</CardText>
<Button
className="mx-auto"
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
</Card>
</Stack>This works with Nav using variant="pills" as well.
Special title treatment
With supporting text below as a natural lead-in to additional content.
Go somewhere<Stack
className="overflow-auto"
gap={3}
>
<Card className="text-center">
<CardHeader>
<Nav variant="pills">
<NavLink
active
href="#"
>
Active
</NavLink>
<NavLink href="#">
Link
</NavLink>
<NavLink
aria-disabled="true"
disabled
>
Disabled
</NavLink>
</Nav>
</CardHeader>
<CardBody>
<CardTitle as="h5">
Special title treatment
</CardTitle>
<CardText>
With supporting text below as a natural lead-in to additional content.
</CardText>
<Button
className="mx-auto"
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
</Card>
</Stack>Images
Cards include a few options for working with images. Choose from appending “image caps” at either end of a card, overlaying images with card content, or simply embedding the image in a card.
Image caps
Similar to headers and footers, cards can include top and bottom “image caps”—images at the top or bottom of a card.
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 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
<Stack
className="overflow-auto"
gap={3}
>
<Card className="mb-3">
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<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>
<small className="fg-2">
Last updated 3 mins ago
</small>
</CardText>
</CardBody>
</Card>
<Card>
<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>
<small className="fg-2">
Last updated 3 mins ago
</small>
</CardText>
</CardBody>
<CardImage
alt="Image cap"
height="180"
placement="bottom"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
</Card>
</Stack>Image overlays
Turn an image into a card background and overlay your card’s text. Depending on the image, you may
need additional styles or utilities through className.
<Stack
className="overflow-auto"
gap={3}
>
<Card theme="inverse">
<CardImage
alt="Card image"
height="270"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22270%22%20viewBox%3D%220%200%20640%20270%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3ECard%20image%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardImageOverlay>
<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>
<small>
Last updated 3 mins ago
</small>
</CardText>
</CardImageOverlay>
</Card>
</Stack>Note that content should not be larger than the height of the image. If content is larger than the image the content will be displayed outside the image.
Card row
Set row on Card to make it horizontal. Set CardImage's placement prop to start or end to position the image at either inline edge.
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
<Stack
className="overflow-auto"
gap={3}
>
<Card
row
style={{
maxWidth: '540px'
}}
>
<CardImage
alt="Image"
height="250"
placement="start"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22250%22%20viewBox%3D%220%200%20640%20250%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<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>
<small className="fg-2">
Last updated 3 mins ago
</small>
</CardText>
</CardBody>
</Card>
</Stack>And with the reverse layout:
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
<Stack
className="overflow-auto"
gap={3}
>
<Card
row
style={{
maxWidth: '540px'
}}
>
<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>
<small className="fg-2">
Last updated 3 mins ago
</small>
</CardText>
</CardBody>
<CardImage
alt="Image"
height="250"
placement="end"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22250%22%20viewBox%3D%220%200%20640%20250%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
</Card>
</Stack>Theme variants
Customize cards by setting the theme prop. By default, cards use bg for their background and border colors; set subtle to use more subtle colors.
Card title
Card text…
Card title
Card text…
Card title
Card text…
Card title
Card text…
Card title
Card text…
Card title
Card text…
Card title
Card text…
Card title
Card text…
<div className="d-grid grid grid-cols-1 md:grid-cols-2 gap-4 overflow-auto">
<Card theme="primary">
<CardHeader>
Primary
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card theme="accent">
<CardHeader>
Accent
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card theme="secondary">
<CardHeader>
Secondary
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card theme="success">
<CardHeader>
Success
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card theme="danger">
<CardHeader>
Danger
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card theme="warning">
<CardHeader>
Warning
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card theme="info">
<CardHeader>
Info
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card theme="inverse">
<CardHeader>
Inverse
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
</div>Card title
Card text…
Card title
Card text…
Card title
Card text…
Card title
Card text…
Card title
Card text…
Card title
Card text…
Card title
Card text…
Card title
Card text…
<div className="d-grid grid grid-cols-1 md:grid-cols-2 gap-4 overflow-auto">
<Card
subtle
theme="primary"
>
<CardHeader>
Primary
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card
subtle
theme="accent"
>
<CardHeader>
Accent
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card
subtle
theme="secondary"
>
<CardHeader>
Secondary
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card
subtle
theme="success"
>
<CardHeader>
Success
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card
subtle
theme="danger"
>
<CardHeader>
Danger
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card
subtle
theme="warning"
>
<CardHeader>
Warning
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card
subtle
theme="info"
>
<CardHeader>
Info
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
<Card
subtle
theme="inverse"
>
<CardHeader>
Inverse
</CardHeader>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
Card text…
</CardText>
</CardBody>
</Card>
</div>Translucent cards
Set translucent on Card to blur and saturate its background. Header and footer backgrounds are also adjusted for a consistent look.
<div className="bg-black overflow-auto">
<Card
className="max-w-100"
style={{
width: '18rem'
}}
translucent
>
<CardBody>
<CardTitle>
Translucent card
</CardTitle>
<CardText>
This card has a translucent background with a backdrop blur effect.
</CardText>
<Button
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
</Card>
</div>Card with header
Headers and footers are also made translucent to maintain a consistent look.
Go somewhere<div className="bg-black overflow-auto">
<Card
className="max-w-100"
style={{
width: '18rem'
}}
translucent
>
<CardHeader>
Featured
</CardHeader>
<CardBody>
<CardTitle>
Card with header
</CardTitle>
<CardText>
Headers and footers are also made translucent to maintain a consistent look.
</CardText>
<Button
href="#"
theme="primary"
variant="solid"
>
Go somewhere
</Button>
</CardBody>
<CardFooter className="fg-2">
2 days ago
</CardFooter>
</Card>
</div>Card layout
In addition to styling the content within cards, Bootstrap includes a few options for laying out series of cards.
Card groups
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.
This layout uses container queries, so place CardGroup inside a query container with the contains-inline utility applied through the parent's className. Without a query container, the cards remain stacked.
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
<Stack
className="max-w-100 overflow-auto p-2"
gap={3}
style={{
resize: 'horizontal'
}}
>
<div className="contains-inline">
<CardGroup>
<Card>
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<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>
<small className="fg-2">
Last updated 3 mins ago
</small>
</CardText>
</CardBody>
</Card>
<Card>
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This card has supporting text below as a natural lead-in to additional
content.
</CardText>
<CardText>
<small className="fg-2">
Last updated 3 mins ago
</small>
</CardText>
</CardBody>
</Card>
<Card>
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<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>
<small className="fg-2">
Last updated 3 mins ago
</small>
</CardText>
</CardBody>
</Card>
</CardGroup>
</div>
</Stack>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.
Card title
This card has supporting text below as a natural lead-in to additional content.
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.
<Stack
className="overflow-auto"
gap={3}
>
<div className="contains-inline">
<CardGroup>
<Card>
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<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 className="fg-2">
Last updated 3 mins ago
</small>
</CardFooter>
</Card>
<Card>
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This card has supporting text below as a natural lead-in to additional
content.
</CardText>
</CardBody>
<CardFooter>
<small className="fg-2">
Last updated 3 mins ago
</small>
</CardFooter>
</Card>
<Card>
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<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 className="fg-2">
Last updated 3 mins ago
</small>
</CardFooter>
</Card>
</CardGroup>
</div>
</Stack>Grid cards
Use Row and Col to control how many cards appear per row. Set responsive column props on Row—for example, xs={1} and md={2}—to lay cards out in one column on small viewports and two equal-width columns from the medium breakpoint up.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
<Stack
className="overflow-auto"
gap={3}
>
<Row
className="g-4"
md={2}
xs={1}
>
<Col>
<Card>
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content. This content is a little bit longer.
</CardText>
</CardBody>
</Card>
</Col>
<Col>
<Card>
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content. This content is a little bit longer.
</CardText>
</CardBody>
</Card>
</Col>
<Col>
<Card>
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content.
</CardText>
</CardBody>
</Card>
</Col>
<Col>
<Card>
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content. This content is a little bit longer.
</CardText>
</CardBody>
</Card>
</Col>
</Row>
</Stack>Change the md prop on Row to 3 and you’ll see the fourth card wrap.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
<Stack
className="overflow-auto"
gap={3}
>
<Row
className="g-4"
md={3}
xs={1}
>
<Col>
<Card>
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content. This content is a little bit longer.
</CardText>
</CardBody>
</Card>
</Col>
<Col>
<Card>
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content. This content is a little bit longer.
</CardText>
</CardBody>
</Card>
</Col>
<Col>
<Card>
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content.
</CardText>
</CardBody>
</Card>
</Col>
<Col>
<Card>
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content. This content is a little bit longer.
</CardText>
</CardBody>
</Card>
</Col>
</Row>
</Stack>When you need equal heights, apply a height utility through each Card's className. To make that the default, set --bs-card-height: 100% in your CSS module.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
Card title
This is a short card.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content.
Card title
This is a longer card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
<Stack
className="overflow-auto"
gap={3}
>
<Row
className="g-4"
md={3}
xs={1}
>
<Col>
<Card className="h-100">
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content. This content is a little bit longer.
</CardText>
</CardBody>
</Card>
</Col>
<Col>
<Card className="h-100">
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a short card.
</CardText>
</CardBody>
</Card>
</Col>
<Col>
<Card className="h-100">
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content.
</CardText>
</CardBody>
</Card>
</Col>
<Col>
<Card className="h-100">
<CardImage
alt="Image cap"
height="140"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22140%22%20viewBox%3D%220%200%20640%20140%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This is a longer card with supporting text below as a natural lead-in to
additional content. This content is a little bit longer.
</CardText>
</CardBody>
</Card>
</Col>
</Row>
</Stack>Just like with card groups, card footers 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.
Card title
This card has supporting text below as a natural lead-in to additional content.
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.
<Stack
className="overflow-auto"
gap={3}
>
<Row
className="g-4"
md={3}
xs={1}
>
<Col>
<Card className="h-100">
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<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 className="fg-2">
Last updated 3 mins ago
</small>
</CardFooter>
</Card>
</Col>
<Col>
<Card className="h-100">
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<CardBody>
<CardTitle>
Card title
</CardTitle>
<CardText>
This card has supporting text below as a natural lead-in to additional
content.
</CardText>
</CardBody>
<CardFooter>
<small className="fg-2">
Last updated 3 mins ago
</small>
</CardFooter>
</Card>
</Col>
<Col>
<Card className="h-100">
<CardImage
alt="Image cap"
height="180"
placement="top"
src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22640%22%20height%3D%22180%22%20viewBox%3D%220%200%20640%20180%22%3E%3Crect%20width%3D%22100%25%22%20height%3D%22100%25%22%20fill%3D%22%23868e96%22%2F%3E%3Ctext%20x%3D%2250%25%22%20y%3D%2250%25%22%20fill%3D%22%23fff%22%20dominant-baseline%3D%22middle%22%20text-anchor%3D%22middle%22%20font-family%3D%22sans-serif%22%20font-size%3D%2224%22%3EImage%20cap%3C%2Ftext%3E%3C%2Fsvg%3E"
width="100%"
/>
<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 className="fg-2">
Last updated 3 mins ago
</small>
</CardFooter>
</Card>
</Col>
</Row>
</Stack>CSS
Variables
Customize the component with the following local CSS variables. Override them through the wrapper’s style prop or your own CSS module.
| CSS variable | Default |
|---|---|
--bs-card-spacer-y | var(--bs-spacer-6) |
--bs-card-spacer-x | var(--bs-spacer-6) |
--bs-card-subtitle-color | inherit |
--bs-card-border-width | var(--bs-border-width) |
--bs-card-border-color | var(--bs-border-color) |
--bs-card-border-radius | var(--bs-radius-7) |
--bs-card-box-shadow | none |
--bs-card-inner-border-radius | calc(var(--bs-card-border-radius) - var(--bs-border-width)) |
--bs-card-cap-padding-y | var(--bs-spacer-3) |
--bs-card-cap-padding-x | var(--bs-spacer-5) |
--bs-card-cap-bg | var(--bs-bg-1) |
--bs-card-cap-color | inherit |
--bs-card-height | auto |
--bs-card-color | inherit |
--bs-card-bg | var(--bs-bg-body) |
--bs-card-img-overlay-padding | var(--bs-card-spacer-y) |
--bs-card-group-margin | 0.75rem |
--bs-card-body-gap | calc(var(--bs-card-spacer-y) * 0.5) |