Context7

Context7

Featured
Developer
upstash/context760,012 stars
Upstash
claudecursorvscodewindsurfgeneric
FreeOpen Source

About This Server

A real-time documentation MCP server by Upstash. Injects up-to-date, version-specific official library docs and code examples into coding agents, eliminating outdated-API hallucinations.

Installation

npx -y @upstash/context7-mcp
Official README installation guide

> [!NOTE]

> API Key Recommended: Get a free API key at context7.com/dashboard for higher rate limits.

Set up Context7 for your coding agents with a single command. The ctx7 CLI requires Node.js 18 or newer.

bash
npx ctx7 setup

Authenticates via OAuth, generates an API key, and installs the appropriate skill. You can choose between CLI + Skills or MCP mode. Use --cursor, --claude, or --opencode to target a specific agent.

To remove the generated setup later, run npx ctx7 remove. If you globally installed the CLI with npm install -g ctx7, remove that package separately with npm uninstall -g ctx7.

To configure manually, use the Context7 server URL https://mcp.context7.com/mcp with your MCP client and pass your API key via the Authorization: Bearer YOUR_API_KEY header. See the link below for client-specific setup instructions.

Manual Installation / Other Clients →

Frequently Asked Questions

What problem does Context7 solve?

AI coding assistants often hallucinate outdated library APIs. Context7 injects up-to-date, version-specific documentation and code examples straight into the prompt, eliminating stale-training-data hallucinations at the source.

How do I install Context7 in Cursor?

Add the command npx -y @upstash/context7-mcp in Cursor MCP settings; for Claude Code use claude mcp add context7 -- npx -y @upstash/context7-mcp. Then just append "use context7" to your prompt.

Is Context7 free? Are there rate limits?

Open source and free to use — you can start without an API key. Anonymous requests are rate-limited; registering for a free key at context7.com raises the limit. Officially maintained by Upstash.