| 1 | # MCPHub: The Unified Hub for Model Context Protocol (MCP) Servers |
| 2 | |
| 3 | English | [Français](README.fr.md) | [中文版](README.zh.md) |
| 4 | |
| 5 | MCPHub makes it easy to manage and scale multiple MCP (Model Context Protocol) servers by organizing them into flexible Streamable HTTP (SSE) endpoints—supporting access to all servers, individual servers, or logical server groups. |
| 6 | |
| 7 |  |
| 8 | |
| 9 | ## 🌐 Live Demo & Docs |
| 10 | |
| 11 | - **Documentation**: [docs.mcphub.app](https://docs.mcphub.app/) |
| 12 | - **Demo Environment**: [demo.mcphub.app](https://demo.mcphub.app/) |
| 13 | |
| 14 | ## 🚀 Features |
| 15 | |
| 16 | - **Centralized Management** - Monitor and control all MCP servers from a unified dashboard |
| 17 | - **Flexible Routing** - Access all servers, specific groups, or individual servers via HTTP/SSE |
| 18 | - **Granular Group Visibility** - Control Tool, Prompt, and Resource visibility independently for each server inside a group |
| 19 | - **Smart Routing** - AI-powered tool discovery using vector semantic search ([Learn more](https://docs.mcphub.app/features/smart-routing)) |
| 20 | - **MCP Apps Proxy** - Transparently forward interactive MCP Apps on single-server routes ([Learn more](https://docs.mcphub.app/features/mcp-apps)) |
| 21 | - **Tool Result Compression** - Transparently reduce large text tool outputs before they reach clients |
| 22 | - **Hot-Swappable Config** - Add, remove, or update servers without downtime |
| 23 | - **OAuth 2.0 Support** - Both client and server modes for secure authentication ([Learn more](https://docs.mcphub.app/features/oauth)) |
| 24 | - **Social Login** - Seamless GitHub and Google login support with Better Auth integration (requires Database Mode) |
| 25 | - **Database Mode** - Store configuration in PostgreSQL for production environments ([Learn more](https://docs.mcphub.app/configuration/database-configuration)) |
| 26 | - **Docker-Ready** - Deploy instantly with containerized setup |
| 27 | |
| 28 | ## 🔧 Quick Start |
| 29 | |
| 30 | ### Configuration |
| 31 | |
| 32 | Create a `mcp_settings.json` file: |
| 33 | |
| 34 | ```json |
| 35 | { |
| 36 | "mcpServers": { |
| 37 | "time": { |
| 38 | "command": "npx", |
| 39 | "args": ["-y", "time-mcp"] |
| 40 | }, |
| 41 | "fetch": { |
| 42 | "command": "uvx", |
| 43 | "args": ["mcp-server-fetch"] |
| 44 | } |
| 45 | } |
| 46 | } |
| 47 | ``` |
| 48 | |
| 49 | 📖 See [Configuration Guide](https://docs.mcphub.app/configuration/mcp-settings) for full options including OAuth, environment variables, and more. |
| 50 | |
| 51 | ### Docker Deployment |
| 52 | |
| 53 | ```bash |
| 54 | # Run with custom config (recommended) |
| 55 | docker run -p 3000:3000 -v ./mcp_settings.json:/app/mcp_settings.json -v ./data:/app/data samanhappy/mcphub |
| 56 | |
| 57 | # Or run with default settings (also mount ./data so credentials and state survive restarts) |
| 58 | docker run -p 3000:3000 -v ./data:/app/data samanhappy/mcphub |
| 59 | ``` |
| 60 | |
| 61 | Two image variants are published under `samanhappy/mcphub`: |
| 62 | |
| 63 | - **`latest`** — the default image. Includes Node.js/pnpm, Python, uv/uvx, Git, and build tools. Covers most MCP servers. |
| 64 | - **`latest-full`** — the extended image. Adds Rust toolchain (Cargo/rustc), Docker Engine, and Playwright browsers (Chrome + Firefox, amd64 only). Use this for Rust-based servers or container-in-container workflows. Larger download. |
| 65 | |
| 66 | See [Docker Setup](https://docs.mcphub.app/configuration/docker-setup) for build options and Docker-in-Docker configuration. |
| 67 | |
| 68 | ### Access Dashboard |
| 69 | |
| 70 | Open `http://localhost:3000` and log in with username `admin`. On first launch, if no `ADMIN_PASSWORD` environment variable is set, a random password is generated and printed to the server logs. You can also pre-set the password: |
| 71 | |
| 72 | ```bash |
| 73 | # Docker: set admin password via environment variable |
| 74 | docker run -p 3000:3000 -e ADMIN_PASSWORD=your-secure-password samanhappy/mcphub |
| 75 | ``` |
| 76 | |
| 77 | > **Tip:** Change the admin password after first login for security. |
| 78 | |
| 79 | > **Headless mode:** Set `DISABLE_WEB=true` to skip serving the bundled dashboard UI and run MCPHub with only the backend/API and MCP endpoints. This is useful when you want to manage servers directly from `mcp_settings.json`. |
| 80 | |
| 81 | ### Connect AI Clients |
| 82 | |
| 83 | Connect AI clients (Claude Desktop, Cursor, etc.) via: |
| 84 | |
| 85 | ``` |
| 86 | http://localhost:3000/mcp # All servers |
| 87 | http://localhost:3000/mcp/{g |