Context7 MCP Server

Context7 MCP Server

by agentify

Up-to-date code documentation for any prompt

180 runs
22 users
Try This Actor

Opens on Apify.com

About Context7 MCP Server

Up-to-date code documentation for any prompt

What does this actor do?

Context7 MCP Server is a web scraping and automation tool available on the Apify platform. It's designed to help you extract data and automate tasks efficiently in the cloud.

Key Features

  • Cloud-based execution - no local setup required
  • Scalable infrastructure for large-scale operations
  • API access for integration with your applications
  • Built-in proxy rotation and anti-blocking measures
  • Scheduled runs and webhooks for automation

How to Use

  1. Click "Try This Actor" to open it on Apify
  2. Create a free Apify account if you don't have one
  3. Configure the input parameters as needed
  4. Run the actor and download your results

Documentation

Context7 MCP Server Context7 MCP Server provides up-to-date, version-specific documentation and code examples straight from the source for any programming library or framework. Get working code answers with the latest APIs and best practices. About this MCP Server: To understand how to connect to and utilize this MCP server, please refer to the official Model Context Protocol documentation at mcp.apify.com. ## Connection URL MCP clients can connect to this server at: text https://mcp-servers--context7-mcp-server.apify.actor/mcp ## Client Configuration To connect to this MCP server, use the following configuration in your MCP client: json { "mcpServers": { "context7": { "url": "https://mcp-servers--context7-mcp-server.apify.actor/mcp", "headers": { "Authorization": "Bearer YOUR_APIFY_TOKEN" } } } } Note: Replace YOUR_APIFY_TOKEN with your actual Apify API token. You can find your token in the Apify Console. ## 🚩 Claim this MCP server All credits to the original authors of https://github.com/upstash/context7 To claim this server, please write to ai@apify.com. --- ## Context7 MCP - Up-to-date Code Docs For Any Prompt ## ❌ Without Context7 LLMs rely on outdated or generic information about the libraries you use. You get: - ❌ Code examples are outdated and based on year-old training data - ❌ Hallucinated APIs that don't even exist - ❌ Generic answers for old package versions ## ✅ With Context7 Context7 MCP pulls 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 prompt in Cursor: txt Create a Next.js middleware that checks for a valid JWT in cookies and redirects unauthenticated users to `/login`. use context7 txt Configure a Cloudflare Worker script to cache JSON API responses for five minutes. use context7 Context7 fetches up-to-date code examples and documentation right into your LLM's context. - 1️⃣ Write your prompt naturally - 2️⃣ Tell the LLM to use context7 - 3️⃣ Get working code answers No tab-switching, no hallucinated APIs that don't exist, no outdated code generation. ## 🔨 Available Tools Context7 MCP provides the following tools that LLMs can use: - resolve-library-id: Resolves a general library name into a Context7-compatible library ID. - libraryName (required): The name of the library to search for - get-library-docs: Fetches documentation for a library using a Context7-compatible library ID. - context7CompatibleLibraryID (required): Exact Context7-compatible library ID (e.g., /mongodb/docs, /vercel/next.js) - topic (optional): Focus the docs on a specific topic (e.g., "routing", "hooks") - tokens (optional, default 5000): Max number of tokens to return. Values less than 1000 are automatically increased to 1000. ## 🛟 Tips ### Add a Rule > If you don't want to add use context7 to every prompt, you can define a simple rule in your MCP client's rule section: > > - For Windsurf, in .windsurfrules file > - For Cursor, from Cursor Settings > Rules section > - For Claude Code, in CLAUDE.md file > > Or the equivalent in your MCP client to auto-invoke Context7 on any code question. > > Example Rule: > > toml > Always use context7 when I need code generation, setup or configuration steps, or > library/API documentation. This means you should automatically use the Context7 MCP > tools to resolve library id and get library docs without me having to explicitly ask. > > > From then on, you'll get Context7's docs in any related conversation without typing anything extra. You can alter the rule to match your use cases. ### Use Library Id > If you already know exactly which library you want to use, add its Context7 ID to your prompt. That way, Context7 MCP server can skip the library-matching step and directly continue with retrieving docs. > > txt > Implement basic authentication with Supabase. use library /supabase/supabase for API and docs. > > > The slash syntax tells the MCP tool exactly which library to load docs for. ## References To learn more about Apify and Actors, take a look at the following resources: - Apify SDK for JavaScript documentation - Apify SDK for Python documentation - Apify Platform documentation - Apify MCP Server - Webinar: Building and Monetizing MCP Servers on Apify - Join our developer community on Discord

Common Use Cases

Market Research

Gather competitive intelligence and market data

Lead Generation

Extract contact information for sales outreach

Price Monitoring

Track competitor pricing and product changes

Content Aggregation

Collect and organize content from multiple sources

Ready to Get Started?

Try Context7 MCP Server now on Apify. Free tier available with no credit card required.

Start Free Trial

Actor Information

Developer
agentify
Pricing
Paid
Total Runs
180
Active Users
22
Apify Platform

Apify provides a cloud platform for web scraping, data extraction, and automation. Build and run web scrapers in the cloud.

Learn more about Apify

Need Professional Help?

Couldn't solve your problem? Hire a verified specialist on Fiverr to get it done quickly and professionally.

Find a Specialist

Trusted by millions | Money-back guarantee | 24/7 Support