---
title: "Empty"
description: "What a page, a panel, or a list shows when it has no content yet: an icon, a short title and text, and buttons for the next step."
url: https://gelatinui.com/components/empty
markdown_url: https://gelatinui.com/components/empty.md
access: free
install: "npx shadcn@latest add @gelatin-ui/empty"
registry_item: https://gelatinui.com/r/empty.json
version: "2026-11-08"
index: https://gelatinui.com/llms.txt
docs_index: https://gelatinui.com/docs/llms.txt
---

# Empty

> What a page, a panel, or a list shows when it has no content yet: an icon, a short title and text, and buttons for the next step.

Page: https://gelatinui.com/components/empty

## When to use it

Best for: A page, a panel, or a list with no content yet: what is missing, and the next step.

- Use it in place of a list with no rows.
- Use `className="border"` for a dashed outline.
- Use `className="bg-muted/50"` for a soft fill.

## When not to use it

- For a failed action, use an [Alert](https://gelatinui.com/components/alert.md).
- For a load that will finish soon, use a [Skeleton](https://gelatinui.com/components/skeleton.md).

## Notes for agents

- It has no border and no fill by default, so it sits in any surface.
- It grows to fill a flex parent.
- `EmptyMedia` has the `icon` and `default` looks.
- Structure comes in as parts: `EmptyHeader`, `EmptyTitle`, `EmptyDescription`, and `EmptyContent`.

## Anatomy

```text
Empty
├─ EmptyHeader (0..n)
├─ EmptyMedia (0..n)
├─ EmptyTitle (0..n)
├─ EmptyDescription (0..n)
└─ EmptyContent (0..n)
```

## API reference

### Empty

No props of its own: `className`, `children`, and every other prop go to the element it renders.

### EmptyHeader

No props of its own: `className`, `children`, and every other prop go to the element it renders.

### EmptyMedia

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `variant` | `"default" \| "icon"` | "default" |  |

### EmptyTitle

No props of its own: `className`, `children`, and every other prop go to the element it renders.

### EmptyDescription

No props of its own: `className`, `children`, and every other prop go to the element it renders.

### EmptyContent

No props of its own: `className`, `children`, and every other prop go to the element it renders.

## Styling

| Part | Slot | States | CSS variables | Tokens |
| --- | --- | --- | --- | --- |
| Empty | `empty` |  |  |  |
| EmptyHeader | `empty-header` |  |  |  |
| EmptyMedia | `empty-media` |  |  |  |
| EmptyTitle | `empty-title` |  |  |  |
| EmptyDescription | `empty-description` |  |  |  |
| EmptyContent | `empty-content` |  |  |  |

## Usage

Put the parts in the root. Add the next step in `EmptyContent`.

The sample also uses `button`, which this add does not write. One command adds them with this item:

```bash
npx shadcn@latest add @gelatin-ui/empty @gelatin-ui/button
```

```tsx title="no-projects.tsx"
import { FolderIcon } from "@phosphor-icons/react/ssr";

import { Button } from "@/components/ui/button";
import {
  Empty,
  EmptyContent,
  EmptyDescription,
  EmptyHeader,
  EmptyMedia,
  EmptyTitle,
} from "@/components/ui/empty";

export function NoProjects() {
  return (
    <Empty>
      <EmptyHeader>
        <EmptyMedia variant="icon">
          <FolderIcon />
        </EmptyMedia>
        <EmptyTitle>No projects yet</EmptyTitle>
        <EmptyDescription>Create your first project to start.</EmptyDescription>
      </EmptyHeader>
      <EmptyContent>
        <Button>Create project</Button>
      </EmptyContent>
    </Empty>
  );
}
```

## Compose

Build it with:

- [Filters](https://gelatinui.com/components/filters.md): Narrows the records.
- [Data Table](https://gelatinui.com/components/data-table.md): Shows the records in rows, with sort and select.
- [Badge](https://gelatinui.com/components/badge.md): Shows the status of each record.
- [Menu](https://gelatinui.com/components/menu.md): Holds the actions of one row.
- [Pagination](https://gelatinui.com/components/pagination.md): Moves between pages.
- [Skeleton](https://gelatinui.com/components/skeleton.md): Holds the layout while the rows load.
- [Command](https://gelatinui.com/components/command.md): Holds the search field and the results.
- [Kbd](https://gelatinui.com/components/kbd.md): Shows the shortcut that opens it.

Rules:

- Every state is designed (`every-state`): Give each view of data its loading, empty, and error states: a skeleton in the final layout, an `Empty` with an illustration and one next action, and an error that says what failed and how to retry.
- Color has a job (`color-has-a-job`): Use color only for a status, the brand action, or data; keep the rest neutral, and show a level with a small mark (a dot, a tinted badge) before a big fill.
- Real content (`real-content`): Fill the UI with content of the real product (real names, amounts, dates, and states), never lorem text or "Item 1".
- Steady text weight (`steady-weight`): Never change the font weight on hover, focus, selected, active, or open; change the color or the fill, so the text does not jump.

Patterns: `gelatin://patterns/data-list`, `gelatin://patterns/command-search`

## Add it

```bash
npx shadcn@latest add @gelatin-ui/empty
```

It adds 6 registry items: 4 files, 1063 lines, and the npm packages `clsx`, `tailwind-merge`, `tailwind-variants`.

## For AI agents

- Every item, one file: https://gelatinui.com/llms.txt
- MCP server (`search_items`, `get_item`, `get_install_plan`): https://gelatinui.com/mcp

## Related

- [Frame](https://gelatinui.com/components/frame.md)
- [Icon Tile](https://gelatinui.com/components/icon-tile.md)
- [Skeleton](https://gelatinui.com/components/skeleton.md)

## Accessibility

The title and the description are plain text in reading order.

It adds no tab stop of its own.
