@arabold/docs-mcp-server

中文文档
3.4.1发布于 2026/10/26MITES Module近 30 天下载 6407

MCP server for fetching and searching documentation

原始使用文档
文档目录11 节
  1. Features
  2. Quick Start
  3. 1. Start the server
  4. 2. Turn on vector search (optional)
  5. 3. Add documentation
  6. 4. Connect your AI client
  7. Command Line
  8. Web Scraping
  9. Documentation
  10. Contributing
  11. License

Grounded Docs MCP Server

Grounded Docs gives your AI coding assistant a documentation index that matches the library versions you use. It fetches documentation from websites, GitHub repositories, npm, PyPI and local folders, and serves search over the Model Context Protocol (MCP), a command line and a web UI. Your assistant answers from that documentation instead of from what it remembers.

It is an open-source alternative to Context7, Nia and Ref.Tools.

Docs MCP Server web interface

Features

  • Indexes websites, GitHub repositories, npm and PyPI packages, local folders and archives (ZIP, TAR).
  • Reads HTML, Markdown, PDF, Office and OpenDocument files, EPUB, Jupyter notebooks, source code and more. See Supported Formats.
  • Stores each library version separately, so a search targets the version your project uses.
  • Combines full-text search with optional vector search through OpenAI, Ollama, Gemini, Vertex AI, AWS Bedrock, Azure OpenAI or any OpenAI-compatible server.
  • Runs on your machine and keeps its index in a local SQLite database. Document text goes only to the embedding provider you configure; with a local one, such as Ollama, it stays on your machine. Usage telemetry is on by default; Telemetry lists what it sends and how to turn it off.
  • Works with any MCP client, over stdio or Streamable HTTP.

Quick Start

You need Node.js 22 or later, or Docker. Installation covers both in detail, along with Docker Compose and running the server inside your AI client.

1. Start the server

npx @arabold/docs-mcp-server@latest

Or with Docker:

docker run --rm \
  -v docs-mcp-data:/data \
  -v docs-mcp-config:/config \
  -p 6280:6280 \
  ghcr.io/arabold/docs-mcp-server:latest

2. Turn on vector search (optional)

Without an embedding model, search uses full-text matching. Vector search also finds passages by meaning. To use OpenAI, start the server with OPENAI_API_KEY set:

OPENAI_API_KEY="sk-proj-..." npx @arabold/docs-mcp-server@latest

With Docker, add -e OPENAI_API_KEY="sk-proj-...". Embedding Models covers Ollama, Gemini, Azure OpenAI and other providers.

Do this before you add documentation. Embeddings are computed when a page is indexed, so documentation indexed without a model gets no vectors until you scrape it again with --replace.

3. Add documentation

Open the web UI at http://localhost:6280 and choose Add library.

4. Connect your AI client

Add the server's MCP endpoint, http://localhost:6280/mcp, to your client. Most clients accept an entry like this:

{
  "mcpServers": {
    "docs-mcp-server": {
      "url": "http://localhost:6280/mcp"
    }
  }
}

Connecting MCP Clients has the exact settings for Claude Code, Claude Desktop, Zed and other clients, how a client can start the server itself over stdio, and the list of MCP tools.

Command Line

The CLI indexes and searches without a running server, which suits scripts and coding agents. It shares its database with a server on the same machine.

# Index documentation
npx @arabold/docs-mcp-server@latest scrape react https://react.dev/reference/react

# Search it
npx @arabold/docs-mcp-server@latest search react "useEffect cleanup" --output yaml

# Fetch one page as Markdown without indexing it
npx @arabold/docs-mcp-server@latest fetch-url https://react.dev/reference/react/useEffect

scrape refuses a library version that already exists. Pass --replace to rebuild it, or run refresh to update it in place. The skills/ directory has Agent Skills that teach coding agents these commands. Basic Usage covers every command, output formats and local files.

Web Scraping

  • Before it crawls a website, a scrape or refresh looks for an llms.txt file in the start URL's directory and at the site root. The links listed there become extra starting points, and for those pages the scraper first tries the Markdown version of the URL, such as /guide/index.html.md or /page.html.md.
  • Requests ask for HTML first, like a browser. Markdown that a server converts on request leaves out the site's navigation, so a crawl would miss most pages. The scraper uses Markdown where the site publishes it: pages listed in llms.txt and links to .md files. A custom Accept header replaces the default one.
  • For documentation sites that route with hash URLs, such as https://docs.example.com/#/guide, turn on hash routes for the scrape. See Hash Route Behavior.

Documentation

Setup:

Usage:

Deployment:

  • Deployment Modes: one process, or a worker with separate MCP and web services.
  • Reverse Proxy Deployment: serve the server under a path such as https://example.com/docs.
  • Authentication: protect the MCP endpoint with OAuth2/OIDC.
  • Security: trust boundaries and limits on what the scraper may reach.
  • Telemetry: the usage events the server sends, and how to turn them off.

Internals:

Contributing

See CONTRIBUTING.md for development setup and guidelines.

License

This project is licensed under the MIT License. See LICENSE for details.

版本与发布记录

@arabold/docs-mcp-server 共发布 86 个版本,首次发布于 2025/03/30;过去 12 个月发布了 39 个版本。

版本发布日期距今
3.4.1latest2026/10/2613 天前
3.4.02026/10/2514 天前
3.3.02026/10/1919 天前
3.2.12026/09/271 个月前
3.2.02026/09/221 个月前
3.1.02026/08/292 个月前

关于 @arabold/docs-mcp-server 的常见问题

@arabold/docs-mcp-server 是什么?

MCP server for fetching and searching documentation

如何安装 @arabold/docs-mcp-server?

在项目目录运行 npm install @arabold/docs-mcp-server,或使用 pnpm add / yarn add / bun add。它还提供命令行工具 docs-mcp-server,可以用 npx docs-mcp-server 直接运行。

@arabold/docs-mcp-server 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/arabold__docs-mcp-server 是否存在。

@arabold/docs-mcp-server 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@arabold/docs-mcp-server 需要什么版本的 Node.js?

package.json 的 engines 字段要求 Node.js >=22。版本不符时 npm 默认只给出警告,开启 engine-strict 后会拒绝安装。

@arabold/docs-mcp-server 可以商用吗?

@arabold/docs-mcp-server 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@arabold/docs-mcp-server 的下载量有多少?

根据 npm 官方下载统计,@arabold/docs-mcp-server 在 2026/10/07 – 2026/11/05 这 30 天内被下载 6,407 次,日均约 214 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@arabold/docs-mcp-server 还在维护吗?

最新版本 3.4.1 发布于 2026/10/26(13 天前);至今共发布 86 个版本,其中过去 12 个月发布了 39 个;首次发布于 2025/03/30。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。