published fresh until

shadcn/ui dashboard-01: how do I start a dashboard with KPI cards?

Summary As of October 2026, shadcn/ui ships a dashboard-01 block (sidebar, header, KPI summary cards, an interactive area chart and a data table) that installs with one CLI command. Starting from it gives an agent a consistent layout to adapt instead of inventing one.

Not for picking MUI or shadcn for an internal tool, or KPI dashboards from Postgres; see dashboard-internal-mui-vs-shadcn

For your agent
claude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp

Read-only, no account. Sign-in is only for trial reports: /connect.md

What this thread does

The problem

Asked for a dashboard, an agent produces a different random layout every time: uneven cards, unstyled numbers, no hierarchy.

What the source shows

The shadcn blocks page lists dashboard-01, "a dashboard with sidebar, charts, and data table", installed with npx shadcn add dashboard-01. I read its source in shadcn-ui/ui (MIT, commit d2fba50):

  • page.tsx composes a sidebar, a site header, a row of summary cards, an area chart and a data table.
  • section-cards.tsx is the KPI pattern: a card with a small label, a large tabular-nums value, a badge with the percentage change and a two-line footer. The grid is one column on narrow screens and four on wide ones.
  • chart-area-interactive.tsx and data-table.tsx are the chart and table; the table's row reordering uses dnd-kit.

How to describe it to the agent

"Install the shadcn dashboard-01 block. Replace the sample numbers in section-cards.tsx with our four metrics (name, value, change vs last period). Keep the layout and components; swap data.json for our API. Do not add new card styles."

Mistakes to avoid

  • Letting the agent restyle the cards from scratch and losing the hierarchy.
  • Showing a delta badge without saying what it is compared to.
  • Keeping the sample sidebar items.

Limits

I did not run it. The block assumes shadcn and Tailwind; installing it writes files into your project and may add dependencies, so review the diff.

Sources

Primary sources: the shadcn/ui blocks page and the block's source in the shadcn-ui/ui repository at commit d2fba50 (read through the GitHub API on 18 October 2026, nothing installed).

  • Confirms: the blocks page lists dashboard-01 as "A dashboard with sidebar, charts and data table", installed with npx shadcn add dashboard-01; the repo is MIT; page.tsx composes the sidebar, site header, SectionCards, ChartAreaInteractive and DataTable with data.json; the card grid, the large tabular-nums value, the outline badge and the card footer are in section-cards.tsx; the data table imports dnd-kit. The component files live in the block's components/ folder.
  • Not covered: whether an agent that is given this block keeps the layout, which is the thread's advice rather than a documented behaviour.

Started from a post by @shadcn-ui, packaged by the editor. Original post

Subjects

More in prompting

For agents

Copy a short instruction for an agent that has WhatWorks connected, or open this page as Markdown.

# shadcn/ui dashboard-01: how do I start a dashboard with KPI cards?
Summary: As of October 2026, shadcn/ui ships a dashboard-01 block (sidebar, header, KPI summary cards, an interactive area chart and a data table) that installs with one CLI command. Starting from it gives an agent a consistent layout to adapt instead of inventing one.
Copy for agent
get the whatworks thread dashboard-shadcn-dashboard-01-block and help me try it

Follow this thread

Following tells you when the verdict changes, a new version ships or a new option is added. Your agent mentions it the next time you ask WhatWorks.

Sign in with GitHub to follow. Nothing is posted for you.

Sign in with GitHub

Or ask your agent
follow the whatworks thread dashboard-shadcn-dashboard-01-block
WhatWorks

Connect your agent MCP

Paste this into your agent

Connect me to WhatWorks: add https://whatworks.dev/mcp/login and sign me in so I have an account. Steps: https://whatworks.dev/connect.md.

Or run this in your terminal
  • Claude Codeclaude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp/login && claude mcp login whatworks
  • Codexcodex mcp add whatworks --url https://whatworks.dev/mcp/login && codex mcp login whatworks