
Context7
Current, version-pinned library docs piped into your coding agent — an open client to Upstash's hosted index
What is Context7?
Ask for a library by name and Context7 resolves it to an identifier like /vercel/next.js, then answers queries with version-specific snippets from a continuously re-indexed documentation corpus — so the model writes against the API that exists today rather than the one in its training data. Setup is one command or a URL pasted into any MCP client, and anyone can submit a public repository to the index. Know what you are adopting: the open-source part is a thin client, while the crawler, parser and index are Upstash's private hosted service — the free tier stops at 1,000 calls a month, and when the hosted endpoint went down for a stretch in August 2026, the tool had nothing to answer from.
What can you do with Context7?
- Wired into your agent with one command — npx ctx7 setup signs you in, issues an API key and writes the configuration for Claude Code, Cursor or OpenCode; any other MCP client just gets the hosted URL pasted in. A CLI and skills mode covers agents that speak no MCP at all.
- Version-pinned answers, one concept per query — A search step resolves a library name to an identifier, a version suffix pins the release you actually run, and the docs tool answers one concept at a time — the tool descriptions themselves push the model toward that rhythm.
- Any public repository can join the index — You need not own a library to submit it. Owners can claim theirs and steer parsing with a context7.json — which folders to include, what to exclude — and refresh runs on popularity or per push via a GitHub Action. Markdown, reStructuredText, plain text and notebooks are parsed, with source code as the fallback.
- The same service outside MCP — A REST API covers search, context fetch and re-indexing, with imports from OpenAPI specs, llms.txt, Notion and Confluence on paid tiers; a TypeScript SDK and Vercel AI SDK tools wrap the same endpoints.
Before you choose Context7
- The corpus is community-submitted and Upstash itself does not guarantee its accuracy — the maintainers run a standing thread collecting duplicate and junk libraries found in the index.Reported in#339
- Major versions reshaped the MCP surface twice in 2026 and renamed tools along the way, so configurations and prompts that name tools need re-checking on upgrade.
Star history
19 Aug to 30 Oct · +3k
Frequently asked questions
Is Context7 free for commercial use?
Context7 is released under the MIT licence — OSI-approved open source, which permits commercial use.
How can Context7 be deployed?
Context7 is available as Runs locally / Managed cloud.