| Option | Values | Description |
|---|---|---|
--pm <manager> | npm, pnpm, yarn, bun | Package manager for create-vite, installs, and shadcn |
-t, --tailwind <version> | v4, v3 | Tailwind CSS version. Interactive prompt when omitted |
-m, --mode <mode> | interactive, quickstart | shadcn init mode. v3 always uses quickstart |
-b, --base <base> | base, radix, aria | Component primitive library for shadcn v4 |
-p, --preset <preset> | preset name | shadcn style preset such as nova or vega |
--no-sample | — | Skip the starter Button and demo |
--no-git | — | Skip git init and the initial commit |
-y, --yes | — | Non-interactive defaults |
-f, --force | — | Allow a non-empty target directory |
Defaults#
Without -y, missing options stay unset so the interactive prompts can ask. Tailwind defaults to v4 in the prompt.
With -y, missing values become:
| Field | Default |
|---|---|
| Project name | my-shadcn-app |
| Package manager | npm |
| Tailwind | v4 |
| shadcn mode | quickstart |
| Sample components | enabled |
| Git | enabled |
| Overwrite non-empty target | disabled |
For Tailwind v3, the shadcn mode is forced to quickstart because the legacy CLI has no interactive library/preset choice.
Examples#
Interactive with defaults:
Tailwind v4 with a specific shadcn setup:
Legacy Tailwind v3 with pnpm:
Overwrite an existing directory intentionally:
Validation rules#
Project names may contain letters, numbers, hyphens, underscores, dots, and @. Path separators, .., leading hyphens, trailing dots, and Windows reserved names are rejected.