Limited-time sale: up to 39% off all plans.Get the deal
Shadcnadmin.com

Search

Search dashboards, components and blocks

AI Tools

Documentation

AI Tools

Build on top of a template with Claude Code, Cursor, Copilot and v0.

Why templates and AI work well together

AI coding tools are at their best when they can follow existing patterns. A Shadcn Admin template gives them exactly that: a consistent design system, typed sample data and dozens of finished pages to copy from. Instead of inventing a layout, the assistant extends yours, so new pages look like they were there from the start.

Give the AI project context

Every tool reads a project instruction file. Add one at the project root that explains the stack, commands and rules. Adjust paths for your framework (for example src/ for React and Vue, src/routes for Svelte).

AGENTS.md
Loading...
  • Claude Code reads CLAUDE.md. Create it with the line @AGENTS.md to reuse the file above.
  • Cursor reads AGENTS.md and rules in .cursor/rules/.
  • GitHub Copilot reads .github/copilot-instructions.md.
  • Codex and other agents read AGENTS.md.
Newer Next.js templates already include an AGENTS.md and CLAUDE.md with framework notes. Add your own rules to them instead of replacing them.

Claude Code

  1. Install and open your project

    Install Claude Code following Anthropic's guide, then start it in the template folder:

    bash
    Loading...
  2. Let it learn the project

    If you don't have a context file yet, run /init. Claude Code scans the project and writes a CLAUDE.md you can refine with the rules above.

  3. Ask for real work

    Describe the outcome and point to an existing page to copy from. Claude Code edits the files, runs pnpm build and fixes what breaks. Review the changes before you commit them.

Cursor

  • Open the project folder in Cursor and let it index the codebase.
  • Use Agent mode for multi-file changes such as a new page, and inline edit (Cmd/Ctrl + K) for small tweaks.
  • Reference files with @, for example @app/(dashboard)/orders/page.tsx, so it copies your patterns instead of guessing.
  • Put the rules from the context file in AGENTS.md or .cursor/rules/.

GitHub Copilot

  • Add .github/copilot-instructions.md with the same content as AGENTS.md.
  • Use Copilot Chat in Agent mode in VS Code for page-level changes, and keep the related files open so they are part of the context.

v0 and other generators

Tools like v0 generate shadcn/ui code, so their output fits our templates well. Generate the piece you need, paste it into a new component, then ask your editor's AI to "restyle this to match the existing cards and use our theme tokens". The result blends in with the rest of the dashboard.

shadcn MCP server

The shadcn CLI includes an MCP server that lets AI assistants browse and install components from shadcn registries. Set it up once in your project:

terminal
Loading...

After a restart you can ask things like "add the calendar and date picker components to this project" and the assistant installs them with the CLI. Remember that components installed this way come with the default shadcn look; ask the assistant to match the template's existing primitives.

Prompts that work

Good prompts name the outcome, point at an example and state the constraints.

Add a page

prompt
Loading...

Connect an API

prompt
Loading...

Rebrand

prompt
Loading...

Good habits

  • Commit before every AI session so you can review the diff and roll back easily.
  • Ask for one feature at a time. Smaller changes are easier to check and fix.
  • Run the build (pnpm build, plus pnpm check in Svelte) after AI changes, and click through the page in light and dark mode.
  • Protect the primitives. Tell the assistant not to rewrite components/ui unless you ask; that is where the template's look comes from.
  • Never paste secrets such as API keys or customer data into prompts.