Cloudflare work is easy for an AI coding assistant to fake. Workers, Durable Objects, D1, R2, Queues, Zero Trust, and Pages all have enough naming overlap that a model can sound right while stitching together the wrong product behavior. cf-docs-mcp is useful because it gives the agent a narrow retrieval tool before it writes code.

The original article should not be saved as a generic search-precision story. The stronger version is a grounding guide for Claude Code, Codex-style MCP clients, and teams that build on Cloudflare. The project exposes a remote Streamable HTTP MCP server, four documentation tools, an inspectable dataset, and a self-hosting path. It also comes with a warning: the public demo is alpha and unauthenticated, so the operator has to draw a line between quick trial and durable team infrastructure.

Why this seed is worth saving

The practical problem is not that Cloudflare docs are unavailable. The problem is that an AI coding session needs the right Cloudflare page at the moment it is editing code. A user asking 'how do I use Durable Objects with WebSockets?' needs a source-linked answer before the model invents an API shape. cf-docs-mcp gives the agent a tool call that returns titles, URLs, snippets, glossary entries, scores, total searched chunks, HyDE availability, and latency. That is a better review artifact than a confident unsourced paragraph.

Add it to Claude Code only as a low-risk trial

The README's fastest Claude Code path is one command: claude mcp add --transport http cf-docs https://cf-docs-mcp.frosty-butterfly-d821.workers.dev/mcp -s user. That is useful for testing, not a blanket production recommendation. The same README says the project is in super alpha and has no authentication yet for the public endpoint. Treat the hosted server as a quick docs-search trial for non-secret queries. Do not paste customer details, private architecture, account IDs, tokens, or unreleased product plans into documentation searches.

Know the four tools

The server exposes search_docs, ask_docs, related_products, and glossary_lookup. Use search_docs when you want ranked chunks and source URLs. Use ask_docs when the model needs cleaner markdown context to answer a question. Use related_products when the user describes a problem and the agent needs to decide between Workers, R2, D1, KV, Queues, or another Cloudflare product. Use glossary_lookup when the risk is terminology confusion. That tool split is the real article, not just the HyDE acronym.

What makes the retrieval different

The README describes the pipeline as synonym expansion, OpenAI embedding, Durable Object SQLite storage, cosine similarity over content and HyDE embeddings, title and heading boosts, MMR diversity deduplication, and ranked results. The source confirms key parts. search.ts uses text-embedding-3-large with 3072 dimensions, scans rows in batches of 2000, fuses content and HyDE scores, boosts title or heading matches, and applies an MMR-style same-file penalty. This is not opaque magic, but it is still retrieval. A reviewer should inspect sources and snippets before trusting the model's final synthesis.

Synonyms are a practical Cloudflare feature

The synonym map is small but important. It maps 'lambda' to Workers, 's3' to R2, 'sqlite' to D1, 'websocket' to WebSockets Durable Objects, 'queue' to Cloudflare Queues, and similar terms. That matters because many developers ask migration questions using AWS or generic vocabulary. A normal keyword search can miss the Cloudflare product name. A coding agent working on migration notes should use that expansion as a starting point, then still cite the returned Cloudflare URL.

The dataset is inspectable

The repo ships a plain NDJSON dataset. The README says the snapshot contains 28,182 chunks from 6,225 MDX files across 99 Cloudflare products, 25,302 HyDE-enriched chunks, and 416 glossary terms. The manifest confirms 28,182 chunk rows across 15 shards plus 416 glossary rows, with no compression. That is useful for a team that does not want to trust a black-box hosted index. You can inspect shard rows, sample URLs, and chunk content before deploying your own Worker.

Check live drift before relying on the public endpoint

The hosted endpoint is alive at the time of this review, but it is not identical to the checked-in Worker code. The repo's health handler returns version 2.0.0; the live /health endpoint returned 3.0.0, and /admin/status returned 30,755 chunks, 27,698 HyDE rows, 419 glossary entries, full-text search rows, and version v2-hybrid. That drift is not automatically bad. It is a reason to verify the runtime before attaching it to a serious workflow. Run /health and /admin/status, then decide whether the public endpoint or your own deployment is the right boundary.

Use official Cloudflare MCP for account operations

cf-docs-mcp should not be confused with official Cloudflare MCP servers. The official Cloudflare page is the right starting point for supported account-scoped operations and vendor-maintained MCP endpoints. cf-docs-mcp is an independent documentation retrieval server with inspectable source and dataset artifacts. The decision rule is simple: if the agent needs to read docs, ask cf-docs-mcp; if it needs to inspect or mutate Cloudflare account resources, use the official path and its authentication model.

Self-hosting is the stable path

For a team, the stable path is private deployment. The README lists Node.js v20+, a Cloudflare account on Workers Paid for Durable Object storage, and an OpenAI API key. The sequence is clone, enter worker, run npm install, deploy with npx wrangler deploy, set OPENAI_API_KEY with npx wrangler secret put OPENAI_API_KEY, seed with node scripts/seed-from-data.mjs --url https://cf-docs-mcp.YOUR.workers.dev, then verify /health and /admin/status. One source-level caution: the README's deploy snippet points at AdrianWilliamsGH/cf-docs-mcp, while the audited repository is ajwcontreras/cf-docs-mcp. Verify the clone target before running commands.

Run acceptance tests before using answers

After adding the MCP server, run three tests. First, ask search_docs for R2 presigned URL expiration settings and confirm the output includes Cloudflare URLs. Second, ask ask_docs for Durable Objects WebSocket hibernation and check whether the answer preserves source sections. Third, ask related_products for a migration problem such as move a Lambda endpoint with S3 file uploads to Cloudflare and verify that Workers and R2 appear for the right reasons. The goal is not a pretty answer; the goal is source-grounded behavior you can audit.

Treat embeddings as data egress

The Worker creates query embeddings with OpenAI. That means the search query leaves the Cloudflare Worker to an embedding provider. For public docs questions, that is usually acceptable. For private customer details, security-sensitive architecture, or incident data, it is a data egress decision. A mature team should write a small policy: documentation-only queries are allowed, secrets are never allowed, customer names are stripped, and private architecture is summarized before retrieval.

Failure modes are straightforward

The README's troubleshooting table is useful because the problems are operational, not philosophical. If the MCP server does not show up, restart the client after adding config. If rate limiting hits, wait 60 seconds because the public endpoint is documented at 30 requests per minute per IP. If the first query is slow, expect Durable Object cold start plus query embedding latency. If no results return, broaden terms or use ask_docs. If seed scripts hit EPIPE during long uploads, the scripts are designed to retry.

The Codex angle

Codex users should read this as a pattern for domain documentation grounding. A good MCP docs tool is narrow, source-linked, testable, and disposable if the source goes stale. For a Cloudflare-heavy repo, cf-docs-mcp can sit beside AGENTS.md instructions that say: before editing Workers, D1, R2, or Durable Objects code, call the docs tool, cite the returned URL in the task notes, then write code. That makes the retrieval artifact part of the engineering record instead of invisible model context.

Save cf-docs-mcp as a Cloudflare docs-grounding article. It is useful for Claude Code and Codex-style workflows when the query is public documentation retrieval; it should not be used for secrets, customer data, or account operations, and teams should self-host before making it part of a durable workflow.

Practical takeaway

Trial the hosted endpoint with claude mcp add --transport http cf-docs https://cf-docs-mcp.frosty-butterfly-d821.workers.dev/mcp -s user, then run health, status, search_docs, ask_docs, and related_products checks. Keep queries documentation-only, cite returned Cloudflare URLs in task notes, compare against official Cloudflare MCP servers for account operations, and deploy a private Worker plus seeded dataset before relying on it across a team.