Context7 MCP Server for Zed
This extension integrates Context7 as a Model Context Protocol (MCP) server for Zed's Assistant, providing up-to-date documentation for any prompt.
Context7 pulls up-to-date, version-specific documentation and code examples straight from the source and places them directly into your prompt context.
LLMs rely on outdated or generic information about the libraries you use. You get:
Context7 fetches up-to-date, version-specific documentation and code examples straight from the source — and places them directly into your prompt.
Add use context7
to your question in Zed Assistant:
How do I use the new Next.js `after` function? use context7
How do I invalidate a query in React Query? use context7
How do I protect a route with NextAuth? use context7
use context7
No tab-switching, no hallucinated APIs that don't exist, no outdated code generations.
This extension can be installed from the Zed extension.
If you're using Zed's agent mode, you need to enable this context server for your assistant:
Write | Ask
button, then click on tools
, then enable the Context7 MCP Server.DEFAULT_MINIMUM_TOKENS
: Set the minimum token count for documentation retrieval (default: 10000).Examples:
{
"context_server": {
"mcp-server-context7": {
"settings": {
"default_minimum_tokens": "10000"
}
}
}
}
The Context7 MCP Server provides these tools to the LLM:
resolve-library-id
: Resolves a general library name into a Context7-compatible library ID.
libraryName
(optional): Search and rerank resultsget-library-docs
: Fetches documentation for a library using a Context7-compatible library ID.
context7CompatibleLibraryID
(required)topic
(optional): Focus the docs on a specific topic (e.g., "routing", "hooks")tokens
(optional, default 5000): Max number of tokens to returnClone the project and install dependencies:
cargo build
MIT
No configuration available
Related projects feature coming soon
Will recommend related projects based on sub-categories