# Stats Section

> "By the numbers" marketing section: heading and intro over a hairline grid of large figures that count up in a staggered wave when the row scrolls into view. Each figure can carry a prefix or unit, a short description, a before/after bar that fills beside a muted baseline, and a footnote that links to its source under the grid. Server and reduced-motion views show final values.

- Slug: `stats-section`
- Category: [Stats](https://www.assembli.design/category/stats.md)
- Type: block
- Tags: stats, metrics, numbers, count-up, social-proof, results
- npm dependencies: motion
- shadcn/ui dependencies: none
- Live preview: https://www.assembli.design/preview/stats-section
- Page: https://www.assembli.design/components/stats-section

![Stats Section preview](https://www.assembli.design/thumbnails/stats-section-light.png)

## Props

Other props pass through to the root element.

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `eyebrow` | `React.ReactNode` | `"By the numbers"` |  |
| `title` | `React.ReactNode` | `"The results speak for themselves"` |  |
| `intro` | `React.ReactNode` |  |  |
| `stats` (required) | `StatsSectionStat[]` |  |  |
| `accent` | `string` |  | The accent color for compare bars, as any CSS color. Defaults to the primary token. |

## Install

One-time setup (needs a subscription):

1. Add the registry to the project's `components.json`: `{"@assembli":{"url":"https://www.assembli.design/r/{name}.json","headers":{"Authorization":"Bearer ${ASSEMBLI_API_KEY}"}}}` (merge into `"registries"`).
2. Put an API key from https://www.assembli.design/account in `.env.local` as `ASSEMBLI_API_KEY=asm_…`.

Then install with the shadcn CLI (writes `components/stats-section/stats-section.tsx` and installs dependencies):

```bash
npx shadcn@latest add @assembli/stats-section
```

Registry item JSON: https://www.assembli.design/r/stats-section.json (send `Authorization: Bearer <api key>`)

## Code

> Component source needs an Assembli subscription ($12/month or $96/year) and an API key sent as `Authorization: Bearer <key>`. To get one without copying anything, POST https://www.assembli.design/api/agent/login (or call the MCP tool connect_account), show the user the link it returns, and poll https://www.assembli.design/api/agent/token for the key. Or subscribe at https://www.assembli.design/pricing and create a key at https://www.assembli.design/account.
