Context7 Server
FreeNot checkedAn MCP server that bridges to the Context7 API, enabling querying documentation context, searching projects, and retrieving project metadata.
About
An MCP server that bridges to the Context7 API, enabling querying documentation context, searching projects, and retrieving project metadata.
README
A Model Context Protocol (MCP) server that acts as a bridge to the Context7 API.
This server allows MCP-compatible clients (like Claude Desktop, IDE plugins, custom applications) to easily interact with Context7's features, including querying documentation context, searching for projects, and retrieving project metadata. It exposes the c7-mcp-server command when installed globally.
⚠️ Important: All data provided through this server comes directly from the official Context7 API (https://context7.com). This server simply provides an MCP interface to that API and does not generate or host any content itself.
Features
Exposes Context7 functionalities via standard MCP capabilities:
- Tools:
c7_query: Query the Context7 API for information on a specific topic within a project. Accepts project name, query text, optional format (txt/json), and optional token limit.c7_search: Search for available Context7 projects by keyword. Returns a list of matching projects (title and usable name).c7_info: Get metadata about a specific Context7 project (like source repository, last update, etc.).
- Resources:
c7_projects_list: Provides a list of all available (valid) Context7 projects via the URIcontext7://projects/list.
Installation
Prerequisites
Option 1: Install from npm (Recommended for Users)
Once published, install the server globally:
npm install -g c7-mcp-server
This will make the c7-mcp-server command available system-wide, allowing MCP clients to launch it.
Option 2: Install from Source (for Development)
- Clone the repository:
git clone <your-repo-url> cd c7-mcp-server - Install dependencies:
npm install # or if using Bun # bun install - Build the server:
npm run build - Link the command locally:
npm link # or if using Bun # bun link
This will make the c7-mcp-server command available on your local machine for testing and development.
Usage
This server is designed to be run by an MCP client application, not typically directly by an end-user (except for testing). The client launches the c7-mcp-server command, and they communicate over standard input/output (stdio) using the MCP protocol.
Configuring with Clients (Example: Claude Desktop)
To use this server with a client like Claude Desktop, you need to add it to the client's configuration file.
Ensure
c7-mcp-serveris installed globally (npm install -g c7-mcp-server) or linked locally (npm link).Edit the client's configuration file (e.g.,
claude_desktop_config.json):- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
- macOS:
Add an entry under
mcpServers:{ "mcpServers": { "context7": { "command": "c7-mcp-server", // The command name installed/linked "args": [] // No arguments needed by default for stdio transport // "env": {} // Add environment variables if needed } // ... other servers ... } }Restart the client application (e.g., Claude Desktop). The client will now launch
c7-mcp-serverin the background and connect to it.
Testing with MCP Inspector
You can test the server directly using the MCP Inspector:
Make sure
c7-mcp-serveris installed globally or linked locally.Run the inspector, telling it to execute your server command:
npx @modelcontextprotocol/inspector c7-mcp-serverThe Inspector UI will open in your browser, connected to your server. Use the "Tools" and "Resources" tabs to interact with the server's capabilities. Check the "Notifications" pane for logs/errors from the server.
MCP Capabilities Details
Tools
c7_query- Description: Query the Context7 API for information on a specific topic within a project.
- Parameters (
object):projectname(string, required): The exact project name (e.g.,nextjs).query(string, required): The topic/question to query.format(enum:"txt"|"json", optional, default:"txt"): Output format.tokens(number, optional): Maximum number of tokens for the response.
- Returns: Text content containing the result from Context7 (either plain text or a JSON string).
c7_search- Description: Search for available Context7 projects by keyword.
- Parameters (
object):term(string, required): The keyword to search for in project titles.
- Returns: Text content containing a JSON string array of matching projects, each with
titleandname(the usable project name).
c7_info- Description: Display metadata about a specific Context7 project.
- Parameters (
object):projectname(string, required): The exact project name.
- Returns: Text content containing a JSON string representation of the project's full metadata.
Resources
c7_projects_list- URI:
context7://projects/list - Description: Provides a list of all available and valid Context7 projects.
- Returns: Content with
mimeType: "application/json"containing a JSON string array of project objects.
- URI:
Development
- Clone the repository.
- Install dependencies (
npm installorbun install). - Build the server (
npm run build). Usenpm run devfor automatic rebuild and start during development. - Link for local testing (
npm linkorbun link). - Test using the MCP Inspector (
npx @modelcontextprotocol/inspector c7-mcp-server). - Make your changes in the
src/directory and rebuild.
License
Install Context7 Server in Claude Desktop, Claude Code & Cursor
unyly install context7-mcp-serverInstalls into Claude Desktop, Claude Code, Cursor & VS Code — handles npx, uvx and build-from-source repos for you.
First time? Get the CLI: curl -fsSL https://unyly.org/install | sh
Or configure manually
Run in your terminal:
claude mcp add context7-mcp-server -- npx -y c7-mcp-serverFAQ
Is Context7 Server MCP free?
Yes, Context7 Server MCP is free — one-click install via Unyly at no cost.
Does Context7 Server need an API key?
No, Context7 Server runs without API keys or environment variables.
Is Context7 Server hosted or self-hosted?
A hosted option is available: Unyly runs the server in the cloud, no local setup required.
How do I install Context7 Server in Claude Desktop, Claude Code or Cursor?
Open Context7 Server on unyly.org, pick your client tab (Claude Desktop, Claude Code, Cursor) and press Install — the config is generated automatically, no JSON editing.
Related MCPs
GitHub
PRs, issues, code search, CI status
by GitHubFilesystem
Secure file operations with configurable access controls.
Memory
Knowledge graph-based persistent memory system.
Template MCP Server
A CLI tool to create a new Model Context Protocol server project with TypeScript support, dual transport options, and an extensible structure
by mcpdotdirectCompare Context7 Server with
Not sure what to pick?
Find your stack in 60 seconds
Author?
Embed badge for your README
Browse similar
All development MCPs
