shadcn-ui-mcp-unofficial

shadcn-ui-mcp-unofficial

35

The Shadcn UI MCP Server is a TypeScript-based MCP server enabling AI assistants to interact with shadcn/ui components. It offers tools to fetch source code, demos, and installation guides to enhance AI model capabilities.

Shadcn UI MCP Server

A TypeScript implementation of a Model Context Protocol (MCP) server designed to help AI assistants interact with shadcn/ui components. It provides features to fetch component source code, demos, and installation guides.

Features

  • Tools
    • get_component: Retrieves the source code of a shadcn/ui component.
    • get_component_demo: Fetches demo code for a component.
  • Resources
    • resource:get_components: Lists all available components.
  • Resource Templates
    • resource-template:get_install_script_for_component: Generates installation script for a component.
    • resource-template:get_installation_guide: Provides framework-specific installation guides.

Running with Docker / Podman

  • Recommended running with Docker Compose.
  • Supports STDIO Server and HTTP/SSE Server modes.

Prerequisites

  • Docker installation is required.
  • Optional Podman installation.

Environment Variables

  • Configure with a .env file based on .env.example.

Using Docker Compose

  1. Build images with docker compose build.
  2. Run HTTP/SSE Server with docker compose up -d mcp-server-http.
  3. Run STDIO Server with docker compose up mcp-server-stdio.
  4. View logs with docker compose logs.
  5. Stop servers with docker compose stop.