48 CZ-PRG (GMT+1)
US-NYC (GMT-5)
Blazor Web App (Server rendered)

A field guide to content containers

Cards.

From a quiet text panel to a full-bleed editorial story, cards make content easier to scan. Learn the Bootstrap 5.3 building blocks, then choose a layout that fits every screen.

Bootstrap 5.3 Mobile first 7 live patterns
00THE IDEA

A card is a container.
The layout is your choice.

Bootstrap's .card is a flexible content surface. It can hold an image, a title, a short description, metadata, actions, or any combination that serves the story.

The card does not decide how neighboring cards line up. Use normal document flow, Flexbox, CSS Grid, or Bootstrap's responsive row-and-column system around it.

01THE BOOTSTRAP BASELINE

Start with the structure.

A card is useful before it is decorated. Every part is optional; the best version includes only what helps someone understand the content or take the next step.

BOOTSTRAP 5.3
LIVE COMPONENT / BASIC STORY CARD STRUCTURE FIRST
FIELD NOTES 6 min read
DESIGN / 04.24

Build a little more room for the story.

A short supporting line can add context without competing with the headline.

Use the body for the essential message. Keep the title clear, the description concise, and the next step easy to find.

Explore the card parts
The image, header, subtitle, link, and footer are optional. The card body is the usual home for content. .card · .card-body · .card-title
THE MINIMUM MARKUPHTML
<article class="card">
  <img class="card-img-top" src="/images/story.jpg" alt="">
  <div class="card-body">
    <h2 class="card-title">A clear headline</h2>
    <p class="card-text">One useful sentence of context.</p>
    <a class="card-link" href="/story">Read the story</a>
  </div>
</article>
02THE PARTS & OPTIONS

A small set of parts.
Plenty of combinations.

Bootstrap's card classes describe the piece of the component. Use standard utilities for spacing, color, alignment, and shape rather than looking for a separate class for every design.

THE SURFACE .card

The root container draws a background, border, radius, and vertical content flow. Add .h-100 when cards in one grid row should stretch to equal height.

THE CONTENT AREA .card-body

Adds the standard inner padding. It is optional when using a header, footer, list group, or image without a padded content block.

TEXT HIERARCHY .card-title · .card-subtitle

Use a real heading element for the title. The classes style it; they do not choose its heading level or create semantic structure.

COPY & LINKS .card-text · .card-link

Use .card-text for supporting copy and .card-link for a simple link. Buttons and other content can be placed in the body too.

CAPS .card-header · .card-footer

Optional top and bottom areas for a category, date, author, controls, or compact metadata. Utility classes can align their contents.

IMAGES .card-img · .card-img-top · .card-img-bottom · .card-img-overlay

Place media above or below the body. Add .card-img-overlay to layer readable content over an image; provide a contrast-safe overlay.

LISTS .list-group.list-group-flush

Attach compact rows of related details between the header, body, and footer without adding a separate outer border.

COLOR .text-bg-primary

Use Bootstrap's .text-bg-* helpers for contextual background and foreground colors, then check contrast for your content.

GROUPING .card-group

Cards stack below 576px, then share an equal-width row and touch at larger sizes. For responsive gaps, uneven widths, or precise breakpoints, use a grid.

HEADER NAVIGATION .card-header-tabs · .card-header-pills

Position a Bootstrap navigation list in the header. These classes style its placement; links or tab behavior still need to be wired intentionally.

ALIGNMENT & SIZE .text-start · .text-center · .w-* · .h-100

Utilities set text alignment and sizing. For responsive widths, prefer grid columns or a CSS layout rather than a fixed card width.

CARD CSS VARIABLES --bs-card-spacer-* · --bs-card-border-* · --bs-card-bg

Bootstrap also exposes variables for title and subtitle color, cap padding and color, card height and text color, image overlay padding, and card-group spacing.

Bootstrap 5 note The old .card-deck and .card-columns patterns are not part of Bootstrap 5. Use .row, columns, or your own CSS Grid instead.

03STYLE WITH UTILITIES

Change the surface.
Keep the hierarchy.

Bootstrap cards do not have a fixed set of visual themes. Combine text and background helpers, borders, radius, shadows, and spacing to match the job of the content.

SURFACE SPACING EMPHASIS
01 / HIGH CONTRAST

A focused announcement.

Use a dark surface for one message that needs a clear moment.

text-bg-dark · border-0
02 / BRAND MOMENT

A confident callout.

Pair a contextual color with concise copy, not a dense article.

text-bg-primary
STATUS

Ready to publish

A restrained border gives status a place without adding visual noise.

HEADER NAVIGATION

Keep related views together.

Use .card-header-pills or .card-header-tabs to align a nav with the card cap.

For real tabs, add working panels and the matching accessible tab behavior.

Useful utilities border-0border-primaryrounded-4shadow-smp-*text-bg-*
TUNE A SURFACEUTILITIES + CSS VARIABLES
<article class="card text-bg-dark border-0 shadow-sm rounded-4">
  <div class="card-body p-4">...</div>
</article>

.brand-card {
  --bs-card-spacer-y: 1.5rem;
  --bs-card-spacer-x: 1.5rem;
  --bs-card-title-spacer-y: .75rem;
  --bs-card-title-color: #20372d;
  --bs-card-subtitle-color: #758279;
  --bs-card-border-width: 0;
  --bs-card-bg: #f1f4ec;
  --bs-card-border-color: transparent;
  --bs-card-border-radius: 1rem;
  --bs-card-inner-border-radius: .75rem;
  --bs-card-height: auto;
  --bs-card-cap-padding-y: .75rem;
  --bs-card-cap-padding-x: 1.5rem;
  --bs-card-cap-bg: transparent;
  --bs-card-cap-color: #68766d;
  --bs-card-color: #30463a;
  --bs-card-img-overlay-padding: 1.25rem;
  --bs-card-group-margin: 1rem;
}

Card CSS variables are useful for a repeated theme. For one-off spacing or shape, the built-in utilities are usually simpler.

04LAYOUT WITHOUT ROWS & COLUMNS

No .row required.
Start with the parent.

A card works on its own in normal document flow. To arrange several cards, use CSS Grid or Flexbox on their parent. The card stays the content unit; the parent owns the layout.

ONE CARD / NORMAL FLOW
A STANDALONE NOTE

A card can simply be a card.

No grid class is needed when the page already provides the width and position.

Set a width on the card or its wrapper only when the design needs one.

SEVERAL CARDS / NATIVE CSS GRID
01 / CSS GRID

Auto-fit columns

Let available space decide how many fit.

02 / FLEXBOX

Wrapped rows

Use .d-flex .flex-wrap .gap-3 for flexible collections.

03 / COMPONENT

Keep it independent

Cards do not need to know their siblings' widths.

NATIVE CSS GRIDNO BOOTSTRAP ROW
<div class="auto-card-grid">
  <article class="card">...</article>
  <article class="card">...</article>
  <article class="card">...</article>
</div>

.auto-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
  gap: 1rem;
}
HORIZONTAL RAIL / FLEX + SCROLL SNAP

A row you can browse.

Useful for a short set of featured stories on mobile. Keep a visible edge of the next card so the horizontal movement is discoverable.

COLLECTION 01

Make the first view count.

A short story for the space between scrolls.

COLLECTION 02

Keep details in reach.

A useful summary can lead to a deeper page.

COLLECTION 03

Leave room to breathe.

A calm rhythm makes a collection easier to scan.

Bootstrap utilities work too Use .d-flex, .flex-wrap, and .gap-* for flexible layouts. Use native CSS Grid when the number and minimum width of columns should adapt automatically. .d-grid is handy for a simple one-column stack, but does not define a card grid for you.

05LAYOUT WITH BOOTSTRAP GRID

Let the columns
set the rhythm.

Bootstrap's grid is the most familiar way to build card collections. Put each card inside a .col; use .row-cols-* for equal-width cards or explicit column widths for a feature layout.

12 COLUMNS RESPONSIVE GUTTERS
EVEN CARD COLLECTION1 → 2 → 3 COLUMNS
01 / DISCOVER

One clear idea.

Each column contains a complete card, not a fragment of one.

See the breakpoints
02 / COMPARE

One shared system.

Consistent gutters keep the collection together as it reflows.

Review the parts
03 / CONTINUE

One next step.

Keep actions consistent and aligned when content lengths vary.

Check the details
row row-cols-1 row-cols-sm-2 row-cols-xl-3 g-3Each .col holds one .card.h-100.

Need one card to lead?

Set different widths on the columns. On small screens both cards stack; at the large breakpoint, the feature gets two-thirds of the row.

FEATURE / 8 OF 12 COLUMNS

Give the most important story more room.

A mixed-width layout can express hierarchy without changing the card component.

01 — LEAD STORY
SUPPORT / 4 OF 12 COLUMNS

Keep the supporting detail close.

Use one parent row and let the columns decide the width.

02 — SUPPORTING STORY
MIXED WIDTHSBOOTSTRAP GRID
<div class="row g-3">
  <div class="col-12 col-lg-8">
    <article class="card h-100">...</article>
  </div>
  <div class="col-12 col-lg-4">
    <article class="card h-100">...</article>
  </div>
</div>

.row provides gutters, .col-* sets width, and .h-100 lets cards fill the column. The card itself remains independent of the layout.

06DESKTOP TO MOBILE

Design small first.
Then add space.

Bootstrap breakpoints are minimum widths. Start with a comfortable single-column card on mobile, then introduce more columns as the content and available space allow.

MOBILE FIRST MIN-WIDTH BREAKPOINTS
BreakpointViewportCommon card decisionExample class
xs / defaultBelow 576pxOne column; full-width cards; stack actions.row-cols-1
sm576px and upTwo compact cards when the text still has room.row-cols-sm-2
md768px and upStart a horizontal image-and-copy card.col-md-4
lg992px and upUse a feature card beside supporting content.col-lg-8
xl1200px and upShow three editorial cards with comfortable gutters.row-cols-xl-3
xxl1400px and upIncrease catalog density if card content stays readable.row-cols-xxl-4
01 / MOBILE CATALOGrow-cols-1 row-cols-sm-2 row-cols-lg-3

Begin with one card per row; add columns only when labels and actions still fit.

02 / WIDE FEATUREcol-12 col-lg-8 + col-12 col-lg-4

Stack the feature and supporting card on mobile, then create hierarchy on desktop.

03 / EQUAL HEIGHTScard h-100 + body d-flex flex-column

Use mt-auto on repeated actions to align them at the foot of each card.

A MOBILE-FIRST CARD GRIDBOOTSTRAP 5.3
<div class="row row-cols-1 row-cols-sm-2 row-cols-lg-3 row-cols-xxl-4 g-3 g-lg-4">
  <div class="col">
    <article class="card h-100">
      <div class="card-body d-flex flex-column">
        <h2 class="card-title h5">A useful title</h2>
        <p class="card-text">A short description.</p>
        <a class="card-link mt-auto" href="/details">Read more</a>
      </div>
    </article>
  </div>
  <!-- Repeat one .col per card -->
</div>

At xs, row-cols-1 applies. Each later class takes effect at its breakpoint and above; no JavaScript is needed.

Let content set the breakpoint. Bootstrap's breakpoint names are tools, not design rules. If a title wraps awkwardly or a button becomes cramped, keep fewer columns for longer.

07MODERN CARD PATTERNS

One component.
Many useful roles.

Use the same card foundation for editorial, commerce, people, data, learning, and pricing. Change the information hierarchy to suit each job, not just the colors.

7 LIVE EXAMPLES RESPONSIVE
EDITORIAL / FEATURE

A view worth staying for.

Use an image overlay when the photograph is part of the story, and protect the text with a gradient.

Explore overlay accessibility
NEW OBJECT
STUDIO GOODS 4.9

Everyday ceramic cup

A product card makes price, details, and the next step easy to compare.

DESIGN / NEW YORK

Maya Chen

Product designer shaping useful digital experiences with thoughtful detail.

ProductResearchSystems
See the card anatomy
WEEKLY REACH
24.8k

18.4% vs. last week

A dashboard card puts one useful signal before its supporting trend.

DESIGN COURSE

A practical guide to visual systems

A learning card can show progress without letting the progress bar replace the course title.

YOUR PROGRESS68%
THE CREATOR PLANPOPULAR
FOR INDEPENDENT WORK

Make room to grow.

$18/ month
  • Unlimited project cards
  • Shared design library
  • Responsive templates
Compare responsive layouts
HORIZONTAL MEDIA CARD

Good for events, updates, and search results.

Stack image and copy by default; place them side by side only when the medium breakpoint gives each enough room.

THURSDAY / 6:30 PM

A conversation about making things that last.

A horizontal card is a content choice, not a new Bootstrap component. Use the same grid utilities inside the card.

See responsive rules
08ACCESSIBLE BY DESIGN

Make the card easy
to read and use.

The .card class is visual styling, not semantic meaning. Choose elements and interaction patterns that explain what the content is and what people can do.

01

Choose the right element

Use <article> for a self-contained story or product. Use a neutral <div> for a purely visual grouping.

02

Keep a clear heading order

Use a real heading for the title and select its level based on the page outline, not the desired font size.

03

Make actions real

Use links to navigate and buttons to perform actions. Avoid making a whole card clickable with a pointer-only handler.

04

Protect image text

Describe meaningful images, use an empty alt for decoration, and add a strong gradient or solid surface behind overlay copy.

05

Keep focus visible

Links and buttons need a visible keyboard focus state. Avoid nested links, or a button inside a stretched card link.

06

Let content reflow

Avoid fixed card heights for variable text. Use .h-100 for a grid row and keep image ratios separate from text height.

A useful test: Can someone understand each card and reach each action using only the page headings, links, and keyboard focus? If not, simplify the card's interaction model.

09QUICK REFERENCE

A practical starting point.

Use this checklist when moving from a sketch to a working card collection.

01

Choose content. Give each card one clear purpose and a useful title.

02

Choose layout. Normal flow, Flexbox, CSS Grid, or Bootstrap .row and .col.

03

Set the mobile view. Start stacked, then add columns and horizontal media at measured breakpoints.

04

Finish with utilities. Apply consistent gutters, spacing, border, radius, color, and image ratio.

05

Check the experience. Review contrast, heading order, focus, alt text, and content overflow.

WEB DESIGN / CARDSONE COMPONENT MANY LAYOUTS
An unhandled error has occurred. Reload 🗙

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.