Research
shadcn/ui Component Statistics 2026: 62 Analyzed
How big shadcn/ui components are, how many use variants and which ones the others are built from, measured from the published source of 62 components on October 26, 2026.
- Updated
- Sample
- 62 components
- Source
- shadcn/ui registry
- Data
- Markdown
Key findings
The median shadcn/ui component is 97 lines of source code, measured across 62 components in the base-vega style; together they come to 8,575 lines.
Denominator: all 62 analyzed components. Link to this finding
Sidebar is the largest shadcn/ui component at 730 lines, followed by Chart (372) and Questionnaire (332). 17 of the 62 components (27%) are 200 lines or longer.
Denominator: all 62 analyzed components. Link to this finding
15 of the 62 shadcn/ui components (24%) define style variants with class-variance-authority (cva); the other 47 have no cva variants.
Denominator: all 62 analyzed components. Link to this finding
22 of the 62 shadcn/ui components (35%) install at least one other shadcn/ui component as a registry dependency; the other 40 stand alone.
Denominator: all 62 analyzed components. Link to this finding
Button is the most reused building block: 14 of the 62 components (23%) depend on it, followed by Separator (4).
Denominator: all 62 analyzed components. A component counts once per dependency it lists. Link to this finding
The median shadcn/ui component exports 4.5 parts; 13 of the 62 components (21%) export a single part and 12 (19%) export 10 or more.
Denominator: all 62 analyzed components. A part is an exported function component. Link to this finding
Components that build on other shadcn/ui components are larger: a median of 208.5 lines for the 22 that do, against 67.5 for the 40 that stand alone.
Two groups: 22 components with registry dependencies and 40 without. Differences under 10% are reported as about the same. Link to this finding
Not reported because the sample is too small:
- Size of components with and without cva variants: only 15 components are in the smaller group, below the 20-row minimum.
Breakdowns
Components by size
Lines of source code per component. Share of all 62 analyzed components. Link to this table
| Lines of source | Components | Share |
|---|---|---|
| Under 50 lines | 14 | 23% |
| 50–99 lines | 17 | 27% |
| 100–199 lines | 14 | 23% |
| 200–399 lines | 16 | 26% |
| 400 lines or more | 1 | 2% |
Components by number of parts
Exported function components per registry item. Share of all 62 analyzed components. Link to this table
| Exported parts | Components | Share |
|---|---|---|
| 1 part | 13 | 21% |
| 2–4 parts | 18 | 29% |
| 5–9 parts | 19 | 31% |
| 10 parts or more | 12 | 19% |
Most reused components
How many of the 62 analyzed components list each one as a registry dependency. Link to this table
| Component | Components that depend on it | Share |
|---|---|---|
| Button | 14 | 23% |
| Separator | 4 | 6% |
| Input | 2 | 3% |
| Input group | 2 | 3% |
| Card | 1 | 2% |
| Collapsible | 1 | 2% |
| Dialog | 1 | 2% |
| Dropdown menu | 1 | 2% |
| Label | 1 | 2% |
| Sheet | 1 | 2% |
| Skeleton | 1 | 2% |
| Textarea | 1 | 2% |
| Toggle | 1 | 2% |
| Tooltip | 1 | 2% |
| use-highlighted-code | 1 | 2% |
| use-mobile | 1 | 2% |
Every component
Ordered by lines of source code, largest first. Link to this table
| Component | Lines | Parts | cva variant groups | Registry dependencies |
|---|---|---|---|---|
| Sidebar | 730 | 23 | 2 | Button, Input, Separator, Sheet, Skeleton, Tooltip, use-mobile |
| Chart | 372 | 3 | 0 | Card |
| Questionnaire | 332 | 15 | 0 | Button |
| Combobox | 328 | 14 | 0 | Button, Input group |
| Menubar | 296 | 16 | 0 | Dropdown menu |
| Context menu | 291 | 15 | 0 | None |
| Dropdown menu | 291 | 15 | 0 | None |
| Toast | 278 | 10 | 0 | Button |
| Code block | 259 | 8 | 2 | Button, use-highlighted-code |
| Carousel | 256 | 5 | 0 | Button |
| Calendar | 245 | 2 | 0 | Button |
| Field | 238 | 10 | 1 | Label, Separator |
| Select | 228 | 9 | 0 | None |
| Drawer | 224 | 11 | 0 | None |
| Command | 210 | 9 | 0 | Dialog, Input group |
| Attachment | 207 | 9 | 3 | Button |
| Item | 201 | 10 | 3 | Separator |
| Alert dialog | 187 | 12 | 0 | Button |
| Navigation menu | 176 | 8 | 0 | None |
| Trace | 167 | 8 | 0 | Collapsible |
| Dialog | 162 | 10 | 0 | Button |
| Input group | 158 | 6 | 2 | Button, Input, Textarea |
| Pagination | 151 | 7 | 0 | Button |
| Sheet | 140 | 8 | 0 | Button |
| Breadcrumb | 137 | 7 | 0 | None |
| Message scroller | 136 | 6 | 0 | Button |
| Bubble | 127 | 4 | 3 | None |
| Table | 115 | 8 | 0 | None |
| Avatar | 108 | 6 | 0 | None |
| Empty | 103 | 6 | 1 | None |
| Card | 102 | 7 | 0 | None |
| Input OTP | 92 | 4 | 0 | None |
| Message | 91 | 6 | 0 | None |
| Popover | 89 | 6 | 0 | None |
| Toggle group | 89 | 2 | 0 | Toggle |
| Accordion | 88 | 4 | 0 | None |
| Button group | 87 | 3 | 1 | Separator |
| Progress | 82 | 5 | 0 | None |
| Tabs | 81 | 4 | 1 | None |
| Alert | 75 | 4 | 1 | None |
| Marker | 70 | 3 | 1 | None |
| Native select | 70 | 3 | 0 | None |
| Tooltip | 65 | 4 | 0 | None |
| Button | 57 | 1 | 2 | None |
| Scroll area | 54 | 2 | 0 | None |
| Badge | 51 | 1 | 1 | None |
| Slider | 51 | 1 | 0 | None |
| Hover card | 50 | 3 | 0 | None |
| Resizable | 49 | 3 | 0 | None |
| Toggle | 44 | 1 | 2 | None |
| Radio group | 37 | 2 | 0 | None |
| Checkbox | 34 | 1 | 0 | None |
| Switch | 31 | 1 | 0 | None |
| Kbd | 26 | 2 | 0 | None |
| Separator | 24 | 1 | 0 | None |
| Aspect ratio | 22 | 1 | 0 | None |
| Spinner | 22 | 1 | 0 | None |
| Collapsible | 21 | 3 | 0 | None |
| Input | 19 | 1 | 0 | None |
| Label | 19 | 1 | 0 | None |
| Textarea | 17 | 1 | 0 | None |
| Skeleton | 13 | 1 | 0 | None |
Methodology
- Source: the shadcn/ui registry index (https://ui.shadcn.com/r/index.json). Every item of type registry:ui, 65 in total, was fetched from https://ui.shadcn.com/r/styles/base-vega/<name>.json on October 26, 2026.
- Included: 62 of the 65 items. Excluded: Direction, because its source exports no function components the parser can read (a re-export or an arrow-function wrapper); Form, because it ships no source code in this style; Sonner, because its source exports no function components the parser can read (a re-export or an arrow-function wrapper).
- Lines: every line of the item's published files joined together, trailing blank lines removed. Comments and blank lines inside the file count.
- Parts: exported functions whose names start with a capital letter. Components written as arrow functions are not counted.
- cva variant groups: keys of the variants object in each cva() call. Registry dependencies: the item's registryDependencies list.
- Not reported: npm dependencies, because the base-vega style declares shared packages such as @base-ui/react once for the whole style rather than on every item.
- One style only: the base-vega style, which is built on Base UI. Radix-based styles may differ in size.
- Every value is computed from published code; none is entered by hand or by users.
- Refreshed when the snapshot is re-fetched with pnpm shadcn:snapshot. The date on this page is the fetch date.
- Percentages are rounded to the nearest whole number, so a table can add up to 99% or 101%. A median of an even count is the mean of the middle two values.
- A finding that compares two groups needs at least 20 components in each group.
Frequently asked questions
How many components does shadcn/ui have?
The shadcn/ui registry listed 65 UI components (items of type registry:ui) on October 26, 2026. HextaUI fetched every one from the base-vega style and measured the 62 that ship readable component source.
Link to this answerWhat is the largest shadcn/ui component?
Sidebar is the largest shadcn/ui component at 730 lines of source code in the base-vega style, measured on October 26, 2026. The median component is 97 lines.
Link to this answerHow many lines of code is a typical shadcn/ui component?
The median shadcn/ui component is 97 lines of source code, across 62 components in the base-vega style measured on October 26, 2026. 17 of the 62 components (27%) are 200 lines or longer.
Link to this answerHow many shadcn/ui components use cva variants?
15 of the 62 shadcn/ui components (24%) define variants with class-variance-authority (cva), measured on October 26, 2026. They include Alert, Attachment, Badge, Bubble and Button.
Link to this answerWhich shadcn/ui component do other components depend on most?
Button. 14 of the 62 shadcn/ui components (23%) list it as a registry dependency, measured on October 26, 2026.
Link to this answerCite this research
Quote any finding with a link to its anchor, or cite the whole study:
HextaUI. “shadcn/ui Component Statistics 2026: 62 Analyzed.” https://hextaui.com/research/shadcn-ui-components. Updated October 2026.
The same findings and tables are at https://hextaui.com/research/shadcn-ui-components.md.