Context7 🔌 MCP server Freemium
Up-to-date, version-specific library documentation for your coding agent
- GitHub stars
- 63k
- Stars this week
- +180
- Forks
- 3.0k
- Licence
- MIT
- Last push
- 2026-10-02
- Maintainer
- upstash
claude mcp add --transport http context7 https://mcp.context7.com/mcpThird-party MCP servers run with your permissions. Read the source before installing, and prefer pinned versions.
Works with
Built on the open MCP standard, so it works in every app that supports MCP.
About Context7
What it does
Context7, from Upstash, gives your coding agent current, version-specific documentation and code examples for the libraries you use. The goal is to stop the agent from writing code against old APIs, or APIs that never existed, that it picked up in training. Ask for something like "Next.js 14 middleware" and Context7 finds the right library and version, then puts the relevant snippets into the agent's context. You can trigger it by adding "use context7" to a prompt, by naming a library ID such as /vercel/next.js, or by adding a rule to your CLAUDE.md or Cursor rules so the agent calls it on its own. The MCP server code is MIT licensed, but the backend, parser and crawler that build the docs index are private.
Tools it gives your agent
resolve-library-id: turns a library name and your question into a Context7 library IDquery-docs: fetches the documentation and examples for that ID that match your question
Works with
Context7 is a remote server at https://mcp.context7.com/mcp, and you can also run it locally from the @upstash/context7-mcp npm package. Its docs have setup steps for more than 30 clients, including Claude Code, Cursor, VS Code, GitHub Copilot, Codex, OpenCode, Cline, Zed and Claude Desktop. There is also a mode that uses a CLI plus a Skill and skips MCP entirely.
How to connect
claude mcp add --transport http context7 https://mcp.context7.com/mcp
With an API key, or to have npx ctx7 setup configure your agent for you:
claude mcp add --header "Authorization: Bearer YOUR_API_KEY" --transport http context7 https://mcp.context7.com/mcp
npx ctx7 setup
Cost and limits
At the time of writing (September 2026), the Free plan includes 1,000 API calls a month for public libraries. Pro costs $10 per seat per month, includes 5,000 calls per seat and adds private repositories. Enterprise pricing is custom. A free API key gives you higher rate limits than calling the server anonymously.
Safety notes
The docs are contributed by the community, and Upstash does not guarantee their accuracy or safety. Treat what comes back as reference material, not instructions. Keep your API key in the request header or an environment variable, and never commit it to a repository.
Pros
- Fixes outdated-API mistakes
- Huge library coverage
- Free tier
Cons
- Rate limits without an API key
Similar MCP servers
All docs & code context MCP servers →MCP Python SDK 🔌 MCP serverOpen source
The official Python SDK for building Model Context Protocol servers and clients
Serena 🔌 MCP serverFree
Semantic code retrieval and editing toolkit for agents, powered by language servers
Codebase Memory MCP 🔌 MCP serverOpen source
Local knowledge graph of your repo so agents query call chains instead of grepping files
pg-aiguide 🔌 MCP serverOpen source
MCP server and skills giving coding agents versioned PostgreSQL and TimescaleDB expertise
MCP Memory Service 🔌 MCP serverOpen source
Self-hosted persistent memory for coding agents with semantic search and a knowledge graph
Grounded Docs MCP Server 🔌 MCP serverOpen source
Self-hosted, version-specific documentation index for coding agents, an open Context7 alternative