MCP ServerHTTPOfficialv1.3.3

Docfork MCP Server

Search and fetch up-to-date documentation for your project dependencies directly in AI coding agents. Prevents hallucinated APIs and outdated code by serving current docs from frameworks, libraries, and custom repositories.

com.docfork/docfork-mcp

Hosted URL

https://mcp.docfork.com

Transport

HTTP

Auth

No auth required

Docfork repository at a glance

Live signal from GitHub, refreshed weekly.

Stars

478

Last commit

May 18, 2026

License

MIT

Language

TypeScript

What the Docfork MCP server does

How models use it and what it is built for.

Search and fetch up-to-date documentation for your project dependencies directly in AI coding agents. Prevents hallucinated APIs and outdated code by serving current docs from frameworks, libraries, and custom repositories.

Connect to Docfork

Hosted endpoint β€” paste into any MCP client.

https://mcp.docfork.com

Resources

Where to find authoritative docs and source for Docfork.

Example prompts for Docfork

Paste any of these into Agent Studio after connecting Docfork.

  • Search for Hono v4 authentication middleware and fetch the current API
  • Find Next.js App Router server-side rendering examples with fetch_doc
  • Search docs for Zod schema validation patterns in our codebase
  • What's the current API for Express middleware in the latest version?

Documentation from project README

View on GitHub

Excerpted from the project's README β€” boilerplate sections (license, changelog, contributing) omitted for clarity.

Context for AI Coding Agents.

WebsiteΒ Β npmΒ Β npm downloadsΒ Β GitHub stars

Docfork demo

AI agents hallucinate APIs, bloat context with stale docs, and write code against outdated signatures. Docfork serves up-to-date documentation directly in Cursor, Claude Code, and Windsurf.

Without Docfork

  app.use('/api/*', jwt({ secret: ... }))
-                       ^^^ removed in Hono v4

With Docfork

  app.use('/api/*', bearerAuth({ verifyToken: ... }))
+                       ^^^ current API, Hono v4.2

Get Started

npx dgrep setup --cursor

Installs the Docfork MCP server in your IDE. Detects your dependencies, provisions an API key, and writes the config file. Also supports --claude and --opencode.

Your agent now has two tools:

Tool Returns
search_docs Ranked documentation sections with titles, URLs, and relevance scores.
fetch_doc Full rendered markdown content from a documentation URL.

No prompt suffix needed:

Set up server-side rendering with Next.js App Router.

Or search from the terminal:

dgrep search "middleware redirect based on authentication" -l vercel/next.js
dgrep search "server actions with forms" -l vercel/next.js

Quickstart β†’ Β· dgrep docs β†’ Β· CLI reference β†’

Your own docs

Index any public or private GitHub repository as a custom library. Your internal APIs, SDKs, and runbooks become searchable by your agents β€” same pipeline as public libraries. GitHub integration setup β†’

Teams

Free: 1,000 requests/month per organization. For team rollout, commit the MCP config to your repo:

// .cursor/mcp.json (committed to git, picked up by every engineer)
{
  "mcpServers": {
    "docfork": {
      "url": "https://mcp.docfork.com/mcp",
      "headers": {
        "DOCFORK_API_KEY": "YOUR_TEAM_API_KEY"
      }
    }
  }
}

Share API keys and Cabinets across your organization. Docfork doesn't store your code or prompts. Security β†’ Β· Pricing β†’

MCP Setup

[!TIP] Run npx dgrep setup --cursor (or --claude, --opencode) to install automatically. Manual config below for other clients.

Cursor β€” Add to Cursor

{
  "mcpServers": {
    "docfork": {
      "url": "https://mcp.docfork.com/mcp",
      "headers": {
        "DOCFORK_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

Claude Code

claude mcp add --transport http docfork https://mcp.docfork.com/mcp/oauth

OpenCode

{
  "mcp": {
    "docfork": {
      "type": "remote",
      "url": "https://mcp.docfork.com/mcp",
      "headers": { "DOCFORK_API_KEY": "YOUR_API_KEY" },
      "enabled": true,
    },
  },
}

Don't see your client? Setup guides for all 29 supported clients β†’

OAuth Authentication

Docfork supports MCP OAuth specs. Change your endpoint to use OAuth:

- "url": "https://mcp.docfork.com/mcp"
+ "url": "https://mcp.docfork.com/mcp/oauth"

Note: OAuth is for remote HTTP connections only. View full OAuth guide β†’

Agent Rule

Add a rule so your agent calls Docfork MCP automatically. Full rule and IDE-specific setup β†’

[!NOTE] Add Rule to Cursor (One-Click)

Claude Code β€” add to your CLAUDE.md:

## Docfork policy

Use Docfork MCP `search_docs` and `fetch_doc` tools for library/API docs, setup, and configuration questions.

- Start `library` with a short name or keyword (e.g., `nextjs`, `zod`). Use the `owner/repo` from the result URL for follow-up calls, never guess it upfront.
- After finding a relevant result, call `fetch_doc` to get the full content. Search results are summaries only.
- Prefer Docfork results over training data when they conflict.
Full rule (all clients)
When writing or debugging code that involves third-party libraries, frameworks, or APIs, use Docfork MCP `search_docs` and `fetch_doc` tools rather than relying on training data.

**Two defaults to follow every time:**

- Start `library` with a short name or keyword (e.g., `nextjs`, `zod`). Use the `owner/repo` from the result URL for follow-up calls, never guess it upfront.
- After finding a relevant result, call `fetch_doc` to get the full content. Search results are summaries only.

Skip Docfork when:

- Language built-ins, general algorithms, syntax stable across versions
- Code or docs the user has already provided in context

When uncertain, default to using Docfork.

FAQ

How is Docfork different from Context7? Both provide MCP servers and CLIs for searching library documentation. Here are the key differences:

  • Stack scoping. dgrep init reads your package.json and scopes all searches to your declared dependencies. Cabinets let you version-pin those libraries across a team.
  • Resolve once, search many. dgrep init resolves package names to canonical identifiers once and caches the mapping in .dgrep/config.json. No per-query resolution step.
  • Hybrid search. Semantic search and BM25 run in parallel, fused via Reciprocal Rank Fusion. AST-aware chunking preserves function boundaries.

Does Docfork store my code or prompts? Your code and prompts never leave your machine. At search time, only the query and library name are sent to Docfork β€” queries are not stored. Indexed documentation content lives in an upstream vector store; private library content is end-to-end encrypted and deleted atomically when you remove the library. Security β†’

What libraries are supported? Docfork maintains a curated catalog of popular frameworks. Add any public or private GitHub repository as a custom library. Add custom libraries β†’

Continue reading on GitHub

Docfork MCP server β€” FAQ

Common questions about connecting and running Docfork.

  • What does Docfork do?

    Docfork is an MCP server that provides two toolsβ€”`search_docs` and `fetch_doc`β€”to search and retrieve up-to-date documentation for your project dependencies. It prevents AI agents from hallucinating outdated APIs by automatically detecting your dependencies and serving current docs from frameworks, libraries, and custom GitHub repositories.

  • How do I set up Docfork?

    Run `npx dgrep setup --cursor` (or `--claude`, `--opencode`) to automatically install the MCP server, detect your dependencies, provision an API key, and configure your IDE. For manual setup, add the HTTP endpoint `https://mcp.docfork.com/mcp` to your MCP config with your `DOCFORK_API_KEY` header, or use OAuth at `https://mcp.docfork.com/mcp/oauth`.

  • What's the pricing and free tier?

    Docfork offers a free tier of 1,000 requests/month per organization. For team rollout, you can commit a shared MCP config with a team API key to your repository so all engineers use the same configuration and quota.

  • Does Docfork store my code or prompts?

    No. Your code and prompts never leave your machine. Only the search query and library name are sent to Docfork servers, and queries are not stored. Private library content is end-to-end encrypted and deleted when you remove the library.

  • Can I index my own internal documentation?

    Yes. You can add any public or private GitHub repository as a custom library, making your internal APIs, SDKs, and runbooks searchable by your agents using the same indexing pipeline as public libraries. Set this up via the GitHub integration in your Docfork dashboard.

Run Docfork across 60+ AI models, side-by-side

Connect Docfork to Claude, GPT, Gemini, DeepSeek and 60+ AI models in MCP Agent Studio. Compare answers side-by-side, save reusable agent presets, share runs β€” all in your browser, no install required.

Open Agent Studio

Related servers

More on MCP Playground