CLI
Use the createui CLI to add Create UI components to your project.
The createui CLI installs Create UI components into your project as plain source files. It reads your components.json, fetches items from the @createui registry, installs their npm dependencies, and writes the component files under your configured aliases. Once the code lands in your project you own it: edit it like any other file.
The CLI is published as @create-ui/cli. Run it with npx:
All components come from the built-in @createui registry. There is nothing
to configure. Items are always referenced by bare name (add button); the
@createui name is only used as the registry argument to search and list.
A typical session looks like this:
Commands
init
Use init to set up Create UI in an existing project. It detects your framework, writes components.json, installs dependencies, adds the cn utility, and writes the theme tokens as CSS variables into your global CSS file.
The command asks for your theme choices interactively. Pass the flags to skip the prompts:
You can also install components in the same step:
Themes
A theme is a swappable token set layered on the single Create UI system. You pick two: a primary theme for the accent palette and a neutral theme for backgrounds, text, and borders.
- Primary themes:
indigo(default),blue,lime,green,red,orange,yellow,cyan - Neutral themes:
gray(default),slate,zinc,base,stone - Font variants:
v1(Geist + JetBrains Mono)
To change the theme later, re-run init with new flags or edit the token variables in your global CSS.
Options
create
Use create to scaffold a brand-new project with Create UI already configured. It prompts for a project name, a template, and your theme choices, then sets everything up.
Available templates:
To start from a preset configuration instead of answering the theme prompts, pass --preset. Use it bare to pick from a list, or pass a preset name or URL directly:
create scaffolds a new project. To set up Create UI inside a project that already exists, use init.
Options
add
Use add to add components and their dependencies to your project. It accepts bare names, URLs, and local paths.
Add several at once:
If a component depends on other registry items (for example, a form control that builds on field), those are added automatically. To replace files you have edited locally, pass --overwrite:
To find out whether installed components are out of date before overwriting anything, use diff.
Options
view
Use view to inspect items before adding them. It prints each item's metadata and file contents as JSON, so you can see exactly what add would write into your project.
You can view multiple items at once:
Options
search
Use search to find items in the registry. The registry name must be prefixed with @.
Without a query, it lists everything. list is an alias for search, so these are equivalent:
Use --limit and --offset to page through long result lists.
Options
diff
Use diff to check installed components against the registry. Without an argument, it lists the components that have updates available:
With a component name, it shows what changed upstream:
Review the diff, then decide per component: if you have no local edits, re-add it with add <name> --overwrite; if you do, apply the upstream changes by hand so your edits survive.
Options
migrate
Use migrate to run a codebase migration. List the available migrations first:
Options
info
Use info to print information about your project: the detected framework, the resolved aliases and paths, and the contents of your components.json. Run it when you need to know where components live, which global CSS file holds the tokens, or how imports should be written.
Options
skill
Use skill to install the Create UI agent skill, a bundled guide that teaches AI coding agents how to write correct Create UI code.
By default it installs for Claude Code in your home directory. Use --client for other agents (claude, gemini, codex, agents), --project to install into the current project instead, or --path for an explicit skills directory.
See the Agent Skill page for the full setup guide.
Options
mcp
Use mcp to run the Create UI MCP server, which lets AI assistants browse, search, and install components from the registry. Running the command starts the stdio server:
You rarely run that yourself. Instead, write the configuration for your MCP client with mcp init:
Supported clients: claude, cursor, vscode, codex, opencode.
See the MCP Server page for client-by-client setup and example prompts.