MCP server

Magic MCP Server (21st.dev)

Generate React UI components from a prompt, inspired by 21st.dev's library. Official: built and maintained by 21st.dev. It runs locally on your machine over stdio. Setup below for 12 clients (checked 2026-10-25). Repo and registry data checked 2026-10-24.
Maintainer
Official · 21st.dev
Runs
Local (stdio)
GitHub
★ 6,236, last push 2026-09-09 (checked 2026-10-24) star history
License
ISC
Connects to
21st.dev
Magic (21st.dev) GitHub star history

Install the Magic MCP Server (21st.dev)

Pick your client. Each tab starts the same local command. Config shapes checked against each client's docs on 2026-10-25.

Run in a terminal. Everything after -- is the command that starts the server. docs

claude mcp add --transport stdio magic -- npx -y @21st-dev/magic@latest

Security notes

  • The local server runs with your user's permissions (npx downloads it from npm on first run). The package is pinned to @latest, so each start can pull a new version; pin a version if you want to review updates.
  • shadcn/uiofficial · ★ 126k

    Browse, search and install components from shadcn/ui and other registries, built into the shadcn CLI.

  • draw.ioofficial · ★ 5.7k

    Create draw.io diagrams from Mermaid or XML, shown live in the chat.

  • Excalidrawofficial · ★ 5.6k

    Draw hand-drawn style Excalidraw diagrams that render live in the chat.

  • AntV Chartofficial · ★ 4.4k

    Generate charts (line, bar, maps, flow diagrams and 20+ more) with AntV.

  • Miroofficial · ★ 163

    Hosted server to read Miro boards and create diagrams, docs and tables on them.

  • Webflowofficial · ★ 140

    Pages, CMS collections and site settings in Webflow, with a Designer companion app.

  • Wixofficial · ★ 15

    Hosted server to build and manage Wix sites, stores, bookings and CMS data.

  • Canvaofficial

    Search, create and export Canva designs from an AI assistant (hosted server).

FAQ

What does the Magic MCP Server (21st.dev) do?+

Generate React UI components from a prompt, inspired by 21st.dev's library.

Is the Magic (21st.dev) MCP server official?+

Official: built and maintained by 21st.dev.

How do I add Magic (21st.dev) to Claude Code?+

Run: claude mcp add magic -- npx -y @21st-dev/magic@latest. Add --scope project to share it with your team through .mcp.json.

How do I use the Magic (21st.dev) MCP server in Cursor or VS Code?+

Open the Cursor or VS Code tab above: it has the mcp.json entry and a one-click install link. Cursor uses the "mcpServers" key; VS Code uses "servers" and needs a type ("stdio").

Does Magic (21st.dev) work in ChatGPT and claude.ai?+

No: it runs locally over stdio, and ChatGPT and claude.ai only connect to remote servers. Use it in Claude Desktop, Claude Code, Cursor, VS Code or another client that can start a local process.

What are the alternatives to the Magic (21st.dev) MCP server?+

Other design & frontend MCP servers: shadcn/ui, draw.io, Excalidraw, AntV Chart and Miro.

All MCP servers · What is an MCP server? · Agent skills