Context7
Current library documentation, fetched instead of remembered
Context7 serves up to date documentation and code examples for a large set of libraries through MCP. It exists to solve one specific failure: a model confidently writing an API that was correct two versions ago.
Best for when
- working with a library that has changed since the model's cutoff
- you keep getting APIs that were correct one major version ago
- you want documentation in context without pasting it yourself
Watch out for
- coverage varies by library, and obscure packages are often missing
- broad questions pull in far more documentation than the task needs
- the hosted service has usage limits, and self hosting is the way around them
Install
Add to Claude Code
claude mcp add context7 -- npx -y @upstash/context7-mcpThe problem it solves
Training data has a cutoff and fast moving libraries do not respect it. The result is code that looks right, imports a function that no longer exists, and costs you twenty minutes to diagnose.
Fetching the current documentation for the exact version in your project removes the guess. This matters most in the frameworks that change fastest, which is exactly where agents are used most.
How to get value from it
It works best when you name the library and the version explicitly. A vague question returns a lot of documentation and fills your context with material the task did not need.
Coverage is per library and not universal. For something obscure or internal, reading the actual source in node_modules remains the reliable move.