Funnel Chart

Shows how much drops off at each step of a process.

Signup funnel data
StageValue (users)Of firstOf previous
Visited pricing18,420100.0%100.0%
Started signup6,21033.7%33.7%
Verified email4,87026.4%78.4%
Began trial2,39013.0%49.1%
Upgraded6123.3%25.6%

Installation

pnpm dlx shadcn@latest add @paneui/funnel-chart

Usage

Examples

Single Color

Horizontal

Descriptions

Keyboard

Each stage is a tab stop; the arrow keys along the funnel's direction move to the next or previous stage. The tooltip shows share of the first stage, conversion from the previous one and the drop-off.

API Reference

FunnelChart

Also accepts every prop of section.

stages*
{ id: string; label: string; value: number; color?: string; description?: string }[]
Stages from top to bottom. Duplicate ids and negative values are skipped.
direction= "vertical"
"vertical" | "horizontal"
Vertical stacks rows with a values column; horizontal flows left to right with a label row.
label= "Funnel"
string
Accessible name.
unit
string
Noun after values in the tooltip.
formatValue= formatNumber
(value: number) => string
Formats stage values.
size= 56 vertical / 220 horizontal
number
Vertical: height of each stage row. Horizontal: plot height.
gap= 4
number
Gap between stages in px.
color
string
One colour for every stage, fading toward the background by depth (readable in light and dark).
minRatio= 0.08
number
Smallest drawn thickness as a fraction of the largest stage.
activeId
string | null
Controlled highlighted stage.
defaultActiveId
string | null
Initially highlighted stage.
onActiveChange
(id: string | null) => void
Called when the highlighted stage changes.
PropTypeDefaultDescription
stages*{ id: string; label: string; value: number; color?: string; description?: string }[]—Stages from top to bottom. Duplicate ids and negative values are skipped.
direction"vertical" | "horizontal""vertical"Vertical stacks rows with a values column; horizontal flows left to right with a label row.
labelstring"Funnel"Accessible name.
unitstring—Noun after values in the tooltip.
formatValue(value: number) => stringformatNumberFormats stage values.
sizenumber56 vertical / 220 horizontalVertical: height of each stage row. Horizontal: plot height.
gapnumber4Gap between stages in px.
colorstring—One colour for every stage, fading toward the background by depth (readable in light and dark).
minRationumber0.08Smallest drawn thickness as a fraction of the largest stage.
activeIdstring | null—Controlled highlighted stage.
defaultActiveIdstring | null—Initially highlighted stage.
onActiveChange(id: string | null) => void—Called when the highlighted stage changes.