shadcn.io is not affiliated with official shadcn/ui
- Group
- Install
- Inputs
base?existing?framework?packageManager?stack?- Access
- Read-only
When to use it
- Before the first component, in a project without shadcn.io yet.
- To start a new app on the preset.
Inputs
base?"base" | "aria" | "ark" | "radix"
React only. Default base (Base UI).
- Type
"base" | "aria" | "ark" | "radix"
existing?boolean
An existing app. Default: a new one.
framework?"react" | "vue" | "svelte" | "solid"
Default react.
- Type
"react" | "vue" | "svelte" | "solid"
packageManager?"npm" | "pnpm" | "yarn" | "bun"
From the lockfile. Default npm.
- Type
"npm" | "pnpm" | "yarn" | "bun"
stack?"next" | "vite" | "tanstack-start" | "react-router" | "astro" | "laravel" | "manual"
React: the app's framework, for its guide.
- Type
"next" | "vite" | "tanstack-start" | "react-router" | "astro" | "laravel" | "manual"
Example prompts
Name the server, so the agent doesn't answer from memory:
Call and response
Asked “Set up a new Vite app with shadcn.io”, the agent sends this call. The response is real, trimmed: long lists show their first items and long strings are cut.
get_project_setup({ framework: "react", stack: "vite" }){
"guide": "## Use the shadcn.io Preset\n\n### Create Project\n\nRun the `init` command with the shadcn.io preset and the Vite template:\n\nRun this answer's …",
"init": "npx shadcn@latest init \"https://kit.dev/r/style.json?token=YOUR_TOKEN\" -t vite",
"next": "Then get_install_command (or get_component with include install) adds components.",
"registry": {
"componentsJson": {
"registries": {
"@shadcnio": {
"headers": "…",
"url": "https://kit.dev/r/{name}.json"
}
}
},
"env": "SHADCNIO_TOKEN=YOUR_TOKEN",
"envFile": ".env.local",
"init": "npx shadcn@latest init @shadcnio/style --force --no-reinstall",
"note": "Optional, to keep the token out of commands: add env to .env.local (out of git), merge componentsJson into components.json, then init and ad…"
},
"stack": "Vite",
"target": "React · Base UI"
}Call it by hand
Your MCP client sends this for you. To try the tool without one, post the call yourself; the server answers in server-sent events, the result on the data: line.
What your agent reads
The server's description of get_project_setup, one of the Install tools. Your agent reads it to decide when to call the tool:
A project's setup, once. React: the shadcn CLI init with our preset, and your stack's guide. Vue, Svelte, Solid: their CLI's setup (shadcn-vue, shadcn-svelte, shadcn), and the same by hand in manual.Next
- get_componentA component, and what you need of it, in one call
- get_install_commandThe shadcn CLI command, token included
FAQ
What does React get when I set up a project?
For React, init with our preset (your token in its URL) writes components.json, the cn helper and the theme. stack adds its guide: create the app, Tailwind, the aliases. existing: true for an app that's already there.
How do I set up Vue, Svelte, or Solid?
Their CLI's setup: commands to run in order (shadcn-vue init with our preset; shadcn-svelte init then our style; the shadcn CLI's init for Solid), and what it needs first (Tailwind CSS v4, the alias). manual has the same by hand: the packages, src/lib/utils.ts, the alias and the theme.