deepseek-websearch-mcp
You can search the web and fetch web pages through this MCP server, which exposes two tools.
web_search — Search the web via DeepSeek's search engine and get structured results with ranking scores, authority, and publish times.
Use advanced query syntax:
site:,-site:,"exact phrase",lang:zh,en,after:2025,before:2026,-exclude.Control results: return 1–50 items (default 10), provide the original question for better intent, set a localization IP, and optionally include page content (
need_content).web_fetch — Fetch a single web page and get its title plus Markdown body.
Fetch any valid HTTP/HTTPS URL (up to 8192 chars, no credentials), typically from a
web_searchresult, to read full content.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@deepseek-websearch-mcp search for recent MCP server security best practices and fetch the top result"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
deepseek-websearch-mcp
基于 DeepSeek 网页搜索与抓取 API 的 MCP server(stdio 传输),为支持 MCP 的 AI 客户端(Claude Code、Cursor、VS Code 等)提供两个工具:
web_search —— DeepSeek 自研搜索引擎,返回带相关性分数、权威性、发布时间的结构化结果,支持
site:、lang:、after:等搜索语法web_fetch —— 抓取单个网页,返回 Markdown 正文
前置要求
Node.js ≥ 20
DeepSeek API Key(Search/Fetch 按成功请求计费:5 元/千次)
Related MCP server: DeepSeek Search MCP
安装与配置
认证信息通过环境变量 DEEPSEEK_API_KEY 注入。
环境变量 | 必填 | 默认 | 说明 |
| 是 | - | DeepSeek API Key,缺失时启动即退出 |
| 否 |
| API 基址(自建网关/调试用) |
| 否 |
| 单次 HTTP 请求超时(毫秒) |
方式一:npx 直接运行(推荐)
npx -y @frankzhang.ai/deepseek-websearch-mcp方式二:全局安装
npm install -g @frankzhang.ai/deepseek-websearch-mcp
deepseek-websearch-mcp方式二备选:从 GitHub 安装(不经 npm registry)
npx -y github:xinzhuang/deepseek-websearch-mcp注意:npm v11 对
npm install -g github:...存在已知缺陷(安装后留下指向已清理临时目录的死链,见 npm/cli#1390 一类问题),如遇command not found请改用上方 registry 安装。
方式三:客户端配置
Claude Code
claude mcp add deepseek-websearch -s user -e DEEPSEEK_API_KEY=sk-你的key -- npx -y @frankzhang.ai/deepseek-websearch-mcpCursor / 通用 JSON(mcp.json)
{
"mcpServers": {
"deepseek-websearch": {
"command": "npx",
"args": ["-y", "@frankzhang.ai/deepseek-websearch-mcp"],
"env": { "DEEPSEEK_API_KEY": "sk-你的key" }
}
}
}VS Code(mcp.json)
{
"servers": {
"deepseek-websearch": {
"command": "npx",
"args": ["-y", "@frankzhang.ai/deepseek-websearch-mcp"],
"env": { "DEEPSEEK_API_KEY": "sk-你的key" }
}
}
}工具说明
web_search
参数 | 类型 | 必填 | 说明 |
| string | 是 | 1~128 字符;支持 |
| integer | 否 | 返回条数 1~50,默认 10 |
| string | 否 | 触发搜索的用户原始问题 |
| string | 否 | 本地化 IP |
| boolean | 否 | 返回网页正文,默认 false(正文较长,按需开启) |
web_fetch
参数 | 类型 | 必填 | 说明 |
| string | 是 | ≤8192 字符的 http/https URL,不允许携带用户名密码 |
错误处理
408/429/5xx 自动指数退避重试(最多 2 次);402 及其余 4xx 不重试
预期内错误以
isError工具结果返回模型可读消息;DEEPSEEK_API_KEY缺失时启动即报错退出限速:Search/Fetch 各 5 QPS(账号级)
开发
npm install
npm run typecheck # 类型检查
npm test # 单元 + stdio 端到端(全 mock,无需 Key)
DEEPSEEK_API_KEY=sk-xxx npm test # 额外运行真实 API 集成测试(会产生计费调用)
npm run build # tsc 构建到 dist/License
Available Tools
2 toolsweb_fetchA
抓取单个网页,返回页面标题与 Markdown 正文。适用于读取 web_search 结果中某个 URL 的完整内容。
Inputs: url (required).
web_searchB
使用 DeepSeek 搜索引擎搜索网页,返回带排序分数、权威性、发布时间的结构化结果。query 支持 site: / -site: / "精确短语" / lang:zh,en / after:2025 / before:2026 / -排除词 等语法。
Inputs: query (required), count, localization, need_content, +1 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 2 tools
web_search and web_fetch have clearly distinct purposes: one searches, the other retrieves page content. No overlap in function, and descriptions explicitly reference how they complement each other.
Both tool names follow a consistent snake_case verb_noun pattern with a shared 'web_' prefix, making the relationship and action clear.
With only 2 tools, the set is thin for a websearch server. While each tool earns its place, the absence of additional operations (e.g., batch fetch or result pagination) makes the count borderline.
The core workflow of searching and fetching pages is covered, and search syntax is rich. Minor gaps like batch fetching or advanced result filtering keep it from being fully complete.
Maintenance
Related MCP Connectors
Live AI-native web search with citations. One tool for every MCP client. Flat per-request pricing.
Scrape, crawl and search the web for AI agents via MCP.
Web search API and MCP server for developers building AI agents.
Official Exa MCP for web search, content fetching, and multi-step research.
Related MCP Servers
- AlicenseBqualityCmaintenanceEnables MCP clients to run web searches via DeepSeek's open platform API, with optional web page fetching that returns Markdown content, and supports query syntax for source, language, and time filters.1118 npm1MIT
- AlicenseNot gradedqualityCmaintenanceEnables MCP clients to run web searches and fetch individual web pages as Markdown through DeepSeek's official Search/Fetch API, with freshness filtering, structured metadata such as publish date, authority and rerank scores, and raw structured output.74 npm4MIT
- AlicenseNot gradedqualityCmaintenanceEnables agents to run web searches and fetch HTTP(S) pages as Markdown via the DeepSeek Search/Fetch API, returning titles, URLs, summaries, publication dates, authority scores, and optional page content. Supports advanced query operators like site:, exact phrases, exclusion terms, lang:, and date-range filters, with retries, timeouts, and structured errors.1MIT
- AlicenseAqualityBmaintenanceExposes DeepSeek's web search and page-fetch tools to any MCP client, letting any LLM run searches with quality signals like rerank score and source authority, plus advanced query syntax. It also retrieves single pages as Markdown, with built-in throttling, retries, and size-conscious summaries.2781 npm3MIT