Context7 MCP Server
by upstashio.github.upstash/context7v4.4.2
Up-to-date code documentation for LLMs and AI code editors.
context tax
~1,188 tok/turn2 tools
security
100/100
cold start
pending
freshness
Active24d ago
Our reading of Context7, from the data
Context7 is a notes & knowledge MCP server from upstash, listed in the official MCP Registry.
Its 2 tools add about 1,188 tokens to every model turn, lighter than the notes & knowledge median of 1,784 tokens across 87 measured servers (measured 2026-10-19).
Maintenance is active: the last public signal was 24 days ago (2026-10-17). For comparison, 70% of notes & knowledge servers are active or maintained.
With 63,264 GitHub stars it ranks #2 of 1,114 notes & knowledge servers we index.
It runs either locally over stdio or as a hosted endpoint and needs one secret (CONTEXT7_API_KEY); use a scoped, least-privilege key.
Install Context7 MCP server
Install in Claude Code
claude mcp add context7 -e CONTEXT7_API_KEY='<context7-api-key>' -- npx -y @upstash/context7-mcpInstall in Cursor
{
"mcpServers": {
"context7": {
"command": "npx",
"args": [
"-y",
"@upstash/context7-mcp"
],
"env": {
"CONTEXT7_API_KEY": "<context7-api-key>"
}
}
}
}Add to ~/.cursor/mcp.json (global) or .cursor/mcp.json (project).
Install in Claude Desktop
{
"mcpServers": {
"context7": {
"command": "npx",
"args": [
"-y",
"@upstash/context7-mcp"
],
"env": {
"CONTEXT7_API_KEY": "<context7-api-key>"
}
}
}
}Settings → Developer → Edit Config (claude_desktop_config.json), then restart.
Install in VS Code
{
"servers": {
"context7": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@upstash/context7-mcp"
],
"env": {
"CONTEXT7_API_KEY": "<context7-api-key>"
}
}
}
}Add to .vscode/mcp.json in your workspace.
Install in Windsurf
{
"mcpServers": {
"context7": {
"command": "npx",
"args": [
"-y",
"@upstash/context7-mcp"
],
"env": {
"CONTEXT7_API_KEY": "<context7-api-key>"
}
}
}
}Add to ~/.codeium/windsurf/mcp_config.json.
Try it in a sandbox first: this installs it with scripts off and starts it with no network, then lists its tools and token cost. How it works
npx mcpskillhub test @upstash/context7-mcp
Configuration
| Variable | Required | Secret | Description |
|---|---|---|---|
| CONTEXT7_API_KEY | — | yes | API key for authentication |
Remote endpoints
- streamable-http
https://mcp.context7.com/mcp
Context tax
Connecting this server adds ~1,188 tokens of tool definitions to every model turn (moderate, 2 tools). Measured 2026-10-19 via its hosted endpoint; o200k tokenizer, worst case for clients that load all tools up front. How we measure
| Model | Per 1,000 turns | With prompt caching |
|---|---|---|
| Claude Opus 5.5 | $4.75 | $0.238 |
| Claude Sonnet 5.5 | $2.38 | $0.238 |
| Claude Haiku 5.5 | $0.119 | — |
Input prices as of 2026-10-06. Excludes your own prompt and output.
Tools (2)
resolve-library-id608 tokResolves a package/product name to a Context7-compatible library ID and returns matching libraries. You MUST call this function before 'Query Documentation' tool to obtain a valid Context7-compatible library ID UNLESS the user explicitly provides a library ID in the format '/org/project' or '/org/project/version' in their query. Each result includes: - Library ID: Context7-compatible identifier (format: /org/project) - Name: Library or package name - Description: Short summary - Code Snippets: Number of available code examples - Source Reputation: Authority indicator (High, Medium, Low, or U
query-docs455 tokRetrieves and queries up-to-date documentation and code examples from Context7 for any programming library or framework. You must call 'Resolve Context7 Library ID' tool first to obtain the exact Context7-compatible library ID required to use this tool, UNLESS the user explicitly provides a library ID in the format '/org/project' or '/org/project/version' in their query. Do not call this tool more than 3 times per question. If you know the programming language the user is working in, pass it as `language` so the results match their setup.
Security signals
100/100 — no known issues found as of 2026-10-19, from the checks below. This is not a guarantee of safety; review what a server can do before connecting it.
Deductions
No findings from the checks that ran.
Checks
- ✓Repository hygiene (archived, activity, license, security policy)
- ✓Tool descriptions (prompt-injection and hidden-text heuristics)
- ○Package metadata (install scripts, provenance) — pending
- ○Source scan (secrets, CVEs, risky code) by vectra-guard — pending
Scan it yourself before installing with vectra-guard, the open-source agent security CLI (made by NavyaAI, which also runs MCPSkillHub). Scoring rules
Freshness
Active — last maintenance signal 24d ago. The newest of the signals below sets the band.
Last commit (default branch)
2026-10-17 · 24d ago · GitHub
Latest release
2026-10-16 · 25d ago · GitHub · ctx7@0.8.0
Package published
no data · npm/PyPI
Registry entry updated
2026-10-15 · 26d ago · official registry · v4.4.2
How it compares in Notes & Knowledge
Against the most-starred notes & knowledge servers we index. Token cost is per model turn, measured from each server's live tool list.
| Server | Stars | Tools | Tokens / turn | Freshness | Runs |
|---|---|---|---|---|---|
| Context7 (this) | 63,264 | 2 | 1,188 | Active | local + hosted |
| Memory | 91,356 | 9 | 949 | Active | local |
| Hindsight | 51,304 | — | not measured | Active | — |
| Cognee | 32,506 | — | not measured | Active | — |
| Docs | 28,892 | 13 | 3,429 | Active | local |
| Skill Seekers | 15,180 | — | not measured | Active | — |
FAQ
›How do I install the Context7 MCP server in Claude Code?
Run: claude mcp add context7 -e CONTEXT7_API_KEY='<context7-api-key>' -- npx -y @upstash/context7-mcp. For Cursor, VS Code, Claude Desktop and Windsurf, use the install tabs above.
›Does Context7 require an API key?
Yes. It expects CONTEXT7_API_KEY, of which 1 is a secret.
›Can I use Context7 as a remote (hosted) MCP server?
Yes — it offers both a hosted endpoint and a local stdio package.
›Is Context7 in the official MCP registry?
Yes, as io.github.upstash/context7.
›How many tokens does Context7 add to my context?
Its tool definitions total about 1,188 tokens, resent on every turn.
Sources and method
- Official MCP Registry entry
- updated 2026-10-15
- GitHub repository
- fetched 2026-10-19
- Package registry (npm / PyPI)
- listed
- Tool list (tools/list), measured by us
- 2026-10-19
- Security signals, computed by us
- 2026-10-19
- Last checked against all sources
- 2026-10-19
The description, packages and links come from the maintainer's own published metadata. Token cost, security signals, freshness and the reading above are MCPSkillHub's own measurements; see the methodology. Editorial standards are owned by Ramachandra Vikas Chamarthi, Founder & AI HPC Architect. Spot an error? Request a correction or claim the listing.
Alternatives to Context7
Other notes & knowledge MCP servers.