Skip to content

shadcn/ui in JetBrains AI Assistant

Add an HTTP server in AI Assistant's settings and Chat, Junie or Claude Agent can find components and install them in the project you have open. It's included with Pro.

Kind
Editor
Goes in
Settings → Tools → AI Assistant → MCP
Connects
Over HTTP
Team config
No

Add it in AI Assistant's settings

AI Assistant takes a JSON snippet on the HTTP tab of its MCP settings. Signed in with Pro, the snippet beside these steps already holds your URL.

  1. Copy the JSON

    It's an mcpServers entry named shadcnio, holding your MCP URL with the token in it. No token yet? Create one on your account page.

  2. Open the MCP settings

    Go to Settings | Tools | AI Assistant | Model Context Protocol (MCP), or type / in AI Chat and pick Add Command. Then click Add.

  3. Paste it on the HTTP tab

    In New MCP Server, choose HTTP, not STDIO: shadcn.io is a remote server. Paste the JSON, pick the global level so every project gets it, and click OK.

  4. Apply, then read Status

    Apply starts the connection, and the Status column shows how it went. There's no IDE restart.

  5. Hand it to the agents

    Chat mode sees the server at once. For Junie, Claude Agent, Codex or GitHub Copilot, turn on Pass custom MCP servers in Settings | Tools | AI Assistant | Agents.

Settings → Tools → AI Assistant → MCP
Sign in to get your config
Sign in with a Pro account, and this holds your MCP URL, ready to paste.

How it reads, with YOUR_TOKEN where your token goes:

{
  "mcpServers": {
    "shadcnio": {
      "url": "https://www.shadcn.io/api/mcp?token=YOUR_TOKEN"
    }
  }
}

At the global level, AI Assistant keeps shadcnio in the IDE's own settings, outside your repositories. The token rides in the URL: if anyone else sees it, make a new one.

Who in a JetBrains IDE reaches shadcnio
Where you askIt reaches shadcnio whenInstructions from
Chat modeThe row is checked and connectedProject rules in .aiassistant/rules
Junie or Codex in AI ChatPass custom MCP servers is onAGENTS.md at the project root
Claude Agent in AI ChatPass custom MCP servers is onCLAUDE.md at the project root
GitHub Copilot in AI ChatPass custom MCP servers is onAGENTS.md and CLAUDE.md
The Junie plugin's own windowIt's in ~/.junie/mcp/mcp.json or .junie/mcp/mcp.json.junie/AGENTS.md, else AGENTS.md

See it connected

Settings | Tools | AI Assistant | Model Context Protocol (MCP) lists every server with its checkbox, its level and its status.

  1. Open Settings | Tools | AI Assistant | Model Context Protocol (MCP) and find the shadcnio row, its checkbox on.
  2. Click the icon in its Status column: the list shows the 22 tools.
  3. Working with an agent? Check Pass custom MCP servers is on in Tools | AI Assistant | Agents.
  4. Send the prompt below in AI Chat: it calls whoami and replies with your account and the calls left this minute.
Prompt
use shadcnio to tell me which account this IDE is connected as

Three tasks, three JetBrains IDEs

A Laravel app in PhpStorm, a React form in WebStorm, a Spring Boot frontend in IntelliJ IDEA: the prompt, the calls, and what lands. Turn the MCP off to compare with the guess you'd get.

Your agent
  1. shadcn.io MCP connected · 22 tools
  2. You: Show the users index as a table with pagination under it.
  3. Agent step: Read package.jsonReturns: Vue 3, @inertiajs/vue3, laravel-vite-plugin, npm
  4. MCP call: get_install_plan({ names: ["table", "pagination"], framework: "vue" })Returns: Both .vue files for resources/js, and the npm packages they import
  5. Agent step: Wrote the files, ran npm install (you chose Yes)Returns: Table and Pagination in resources/js/components/ui
  6. Agent step: Edited resources/js/Pages/Users/Index.vueReturns: Rows from the Inertia props, a page link per page
  7. Your agent: Users/Index.vue renders a Table now, with Pagination under it fed by the paginator's links.

In your project

Table

  • Two Vue components, in your ui folder
  • Page links from Laravel's paginator

1 prompt → 1 MCP calls

Prompts for AI Chat

Paste one into Chat mode or an agent. @thisFile and @selection aim it at the code in your editor; naming the server keeps it on the registry.

01
use shadcnio to add a combobox for the country field in @thisFile
02
use shadcnio to rebuild the Vue registration page in resources/js/Pages/Auth with a password input and an error under each field
03
use shadcnio to plan a landing page for our Kotlin library from blocks, then install the picks in the docs frontend
04
use shadcnio to swap the emoji in @selection for Lucide icons that mean build, test and deploy
05
use shadcnio to read the Select API before you fix the controlled value in @thisFile
06
use shadcnio to add a kanban board to the issues page, with open, in review and done columns
07
use shadcnio to set up the SvelteKit frontend in this monorepo for shadcn components
08
use shadcnio to restyle the admin panel after a dark fintech DESIGN.md and save that file at the root

What helps inside a JetBrains IDE

Agents, rules, trimming and models: the AI Assistant settings that decide how well the registry works for you.

  • Pass the server to agents

    Junie, Claude Agent, Codex and GitHub Copilot see MCP servers only with Pass custom MCP servers on. Their / menu won't list the tools either, so name shadcnio in the prompt.

  • A rule for Chat, AGENTS.md for agents

    Chat mode follows project rules in .aiassistant/rules: make one with the Always type. Junie and Codex read AGENTS.md and Claude Agent CLAUDE.md, so put the same line there.

    For UI work, use the shadcnio MCP: look for a component or block before writing one, and install it with the command it returns.
  • Mind the trimming threshold

    AI Assistant trims tool results past a share of the model's context window, which can cut a component's source short. Raise Trim message if it exceeds % of a model context window in Settings | Tools | AI Assistant, or ask for fewer include sections.

  • Allow the reads, approve the installs

    Every shadcnio tool only reads, so Always allow on Junie's first request for one is safe. With Brave mode on Safe, the npx shadcn add that follows still waits for your Yes.

  • Pick a model that calls tools

    With a model from Ollama or LM Studio, AI Assistant can't call MCP tools, and agents don't take local models. For an OpenAI-compatible endpoint, turn on Tool calling in Providers & API keys.

  • Slash commands in Chat mode

    In Chat mode, type /: a connected server adds its tools to the list beside /explain and /web, to call one by hand. Add @thisFile to the same message to aim it at the open file.

When shadcnio won't answer

What the Status column or AI Chat shows, and the fix for each. Errors that come from the server rather than the IDE are covered in the troubleshooting guide.

The Status column shows an error for shadcnio.
Open Help | Show Log in Finder (Show Log in Explorer on Windows) and read the server's log in the mcp folder. A URL cut off while pasting is the usual cause: select the row, Edit, paste the JSON again, Apply.
Calls fail with 401.
The URL holds an old token, or none: regenerating it on your account ends the previous one. Copy the JSON from this page again, Edit the shadcnio row, paste and Apply.
Calls fail with 403.
shadcn.io knows the token but finds no Pro plan running on that account. Renew it on your account page, then click Reconnect on the shadcnio row; the JSON stays as it is.
Chat mode uses shadcnio, but Junie or Claude Agent says it has no such tools.
Agents get configured servers only with Pass custom MCP servers on, in Settings | Tools | AI Assistant | Agents. Turn it on, click OK, and start a new chat.
The MCP settings won't let you add a server.
Your organization manages AI through JetBrains IDE Services or JetBrains Central, and its admin controls which MCP servers you can connect. Ask them to allow servers of your own.
AI Assistant never calls the tools, and shows no error.
Look at the model picker: with a local model from Ollama or LM Studio, AI Assistant can't call MCP tools. Pick a cloud model, then name the server in the prompt (use shadcnio…).

Get the MCP for JetBrains with Pro

The MCP comes with every Pro plan, with every block and premium template, for you or your whole team. Monthly, yearly or lifetime.

4.9/5 out of 5 · 150+ reviewsfrom 150+ founders and developers.

  • Secure checkout via Stripe
  • Code lives in your repo
  • Keep what you've shipped if you cancel
  • License terms

Frequently asked questions

The shadcn MCP in JetBrains: setup, limits, and the rest.

4.9 out of 5 from 150+ developers

Put the registry in AI Chat

Components, 6,231 blocks and 294k icons for Chat mode, Junie and Claude Agent, in IntelliJ IDEA, WebStorm and the rest, with any Pro plan.

Get Pro