context7-mcp
Fetch current library and framework documentation from Context7 instead of relying on training data
Context7 Documentation Lookup
Overview
Use Context7 MCP to fetch current, accurate documentation for any library, framework, or API. Always prefer this over training data for code generation, setup questions, and API references.
The Process
- Resolve: Call
resolve-library-idwith the library name and the user's question. - Select: Pick the best match — prefer exact names, higher benchmark scores, and version-specific IDs when a version is mentioned.
- Fetch: Call
query-docswith the selected library ID and the user's question. - Answer: Use the fetched docs — include code examples and cite the version.
Guidelines
- Pass the user's full question as the query for better relevance
- When users mention versions (e.g., "Next.js 15"), use version-specific library IDs
- Prefer official/primary packages over community forks