zenrows-mcp
OfficialZenRows MCP 服务器
ZenRows MCP (Model Context Protocol) 服务器是 AI 系统使用 ZenRows 的标准方式。只需一个连接,您的 AI 助手、智能体或应用程序即可实时访问任何网站。
📚 完整文档: docs.zenrows.com/integrations/mcp/mcp-overview
为什么选择 ZenRows MCP
访问通常会屏蔽机器人的网站。 无需担心被反爬虫系统拦截,即可大规模访问任何网站。
托管式抓取基础设施。 代理轮换、无头浏览器编排、反爬虫规避和会话管理均在 ZenRows 基础设施上运行。
接入您现有的任何 AI。 适用于任何 MCP 客户端,包括 AI 助手、智能体框架、AI SDK、IDE 插件和自定义应用程序。
纯英语指令,无需编写抓取代码。 自然地描述任务,AI 会自动选择合适的工具。无需选择器、无需管理代理、无需调整反爬虫设置。
Related MCP server: defuddle-mcp
快速入门
ZenRows MCP 支持两种传输选项。两者都提供相同的工具集和功能。选择最适合您客户端的一种。
远程 MCP 服务器
当您的 AI 应用程序直接调用 LLM API 时,请使用托管的 ZenRows MCP 服务器。该服务器运行在 ZenRows 基础设施上,因此无需安装、配置或更新。
服务器 URL:
https://mcp.zenrows.com/mcp传输方式: Streamable HTTP
身份验证: 基于 OAuth。在每次请求的 Authorization 标头中以 Bearer 令牌形式传递您的 ZenRows API 密钥。
Authorization: Bearer YOUR_ZENROWS_API_KEY大多数 MCP 客户端通过工具配置中的 authorization 简写字段接受此信息,并自动将其转发为 Bearer 令牌。有些客户端则使用自由格式的 headers 字段。两种方法均可。
示例:OpenAI Responses API
import os
from openai import OpenAI
ZENROWS_API_KEY = os.environ["ZENROWS_API_KEY"]
client = OpenAI(api_key=os.environ["OPENAI_API_KEY"])
response = client.responses.create(
model="gpt-5",
tools=[
{
"type": "mcp",
"server_label": "zenrows",
"server_description": "Web scraping MCP server for accessing live web content.",
"server_url": "https://mcp.zenrows.com/mcp",
"authorization": ZENROWS_API_KEY,
"require_approval": "never",
}
],
input="Visit https://news.ycombinator.com/ and summarize the three most recent posts.",
)
print(response.output_text)有关包含特定框架示例的完整演练,请参阅 远程 MCP 服务器文档。
本地 MCP 服务器
当您的 MCP 客户端将服务器作为本地子进程运行,而不是调用远程 URL 时,请使用本地 stdio 配置。这是桌面 AI 工具和 IDE 插件(包括 Claude Desktop、Claude Code、Cursor、Windsurf、VS Code、Zed 和 JetBrains IDE)的标准设置。
包: @zenrows/mcp (位于 npm)
身份验证: 通过 ZENROWS_API_KEY 环境变量提供 API 密钥。
要求: 已安装 Node.js (以便使用 npx)。
配置:
{
"mcpServers": {
"zenrows": {
"command": "npx",
"args": ["-y", "@zenrows/mcp"],
"env": {
"ZENROWS_API_KEY": "YOUR_ZENROWS_API_KEY"
}
}
}
}此配置的具体位置因客户端而异。请参阅 各客户端设置指南 以获取您客户端的文件路径。
工具
ZenRows MCP 公开了两类工具:
scrape:单次请求抓取,返回 Markdown、纯文本、HTML、JSON、PDF 或截图。由 通用抓取 API 提供支持。browser_*:30 多种用于完整浏览器自动化的工具,包括导航、点击、表单填写、JavaScript 执行、Cookie、标签页和持久会话。由 抓取浏览器 提供支持。
AI 会根据您的提示选择合适的工具。您无需在代码中直接调用工具。
请参阅 完整工具参考 以了解每个工具、参数和返回值。
开发
git clone https://github.com/ZenRows/zenrows-mcp
cd zenrows-mcp
npm install
cp .env.example .env # Add your API key
npm run dev # Run with .env loaded (requires Node.js 20.6+)
npm run build # Compile to dist/
npm run inspect # Open the MCP inspector UI欢迎提交 Pull Request 和 Issue。
资源
许可证
Available Tools
1 toolscrapeARead-onlyInspect
Scrape any webpage and return its content using ZenRows.
Use this tool to fetch webpage content for analysis. By default it returns clean markdown, which is ideal for LLM processing.
When to enable options:
js_render: page uses React/Vue/Angular, loads content dynamically, or content appears missing on the first attempt
premium_proxy: site returns 403/blocked errors even with js_render enabled
wait_for: specific content loads after initial render (requires js_render)
css_extractor: you only need specific elements, not the whole page
autoparse: structured data pages like products or articles
Examples: Basic: { url: "https://example.com" } Dynamic: { url: "https://spa.com", js_render: true } Protected:{ url: "https://protected.com", js_render: true, premium_proxy: true } Extract: { url: "https://shop.com", css_extractor: '{"title":"h1","price":".price"}' }
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The webpage URL to scrape | |
| js_render | No | Enable JavaScript rendering via headless browser. Required for SPAs (React, Vue, Angular) and pages that load content dynamically. | |
| premium_proxy | No | Use premium residential proxies to bypass anti-bot protection. Required for heavily protected sites. Implies higher credit cost. | |
| proxy_country | No | Country for geo-targeted scraping. ISO 3166-1 alpha-2 code (e.g. 'US', 'GB', 'DE'). Requires premium_proxy=true. | |
| response_type | No | Output format. 'markdown' (default) preserves structure and is ideal for LLMs. 'plaintext' strips all formatting for pure text extraction. 'pdf' returns a PDF of the page. 'html' returns the raw HTML source (omits the response_type param; ZenRows default). Ignored when autoparse, css_extractor, outputs, or screenshot params are set. | markdown |
| autoparse | No | Automatically extract structured data from the page into JSON. Best for product pages, articles, and listings. | |
| css_extractor | No | Extract specific elements using CSS selectors. JSON object mapping names to selectors, e.g. '{"title":"h1","price":".price-tag"}'. Returns JSON instead of full page content. | |
| wait_for | No | CSS selector to wait for before capturing. Use when key content loads after the initial page render. Requires js_render=true. | |
| wait | No | Milliseconds to wait after page load before capturing content. Max 30000 (30s). Requires js_render=true. | |
| js_instructions | No | JSON array of browser interactions to run before scraping. Requires js_render=true. Example: [{"click":"#load-more"},{"wait":1000},{"wait_for":".results"}] | |
| outputs | No | Comma-separated list of data types to extract as structured JSON. Available: emails, headings, links, menus, images, videos, audios. Use '*' for all types. Returns JSON instead of full page content. | |
| screenshot | No | Capture an above-the-fold screenshot of the page. Returns an image instead of text content. Useful for visual verification or debugging. | |
| screenshot_fullpage | No | Capture a full-page screenshot including content below the fold. Returns an image instead of text content. | |
| screenshot_selector | No | Capture a screenshot of a specific element using a CSS selector. Example: ".product-card". Returns an image instead of text content. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and destructiveHint=false. Description adds valuable behavioral context: default markdown output ideal for LLMs, and crucially explains that certain parameters (css_extractor, autoparse, outputs, screenshot) change the return type from text to JSON or images. This output-switching behavior is not captured in annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Well-structured with clear information hierarchy: purpose statement, default behavior, conditional options guide, and examples. Every section earns its place. Examples section is slightly verbose but appropriate for a 14-parameter tool where syntax matters. Good use of formatting (bullet points, code blocks).
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a complex tool with 14 parameters and no output schema, description adequately explains return value variations (markdown default vs JSON vs images depending on params). Covers the ZenRows-specific options (premium_proxy credit cost mentioned in schema, wait_for interactions explained). Could mention error handling or rate limits, but sufficient for invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, establishing baseline 3. Description adds significant value via the 'When to enable options' section which provides contextual semantics for when to use parameters (e.g., 'page uses React/Vue/Angular' triggers js_render). The concrete examples demonstrate parameter interactions and valid value formats (e.g., CSS selector JSON syntax).
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Opens with specific verb+resource ('Scrape any webpage') and identifies the underlying service ('using ZenRows'). Clearly states default output format ('clean markdown') and primary use case ('fetch webpage content for analysis'). No siblings to differentiate from, but scope is precisely defined.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Contains explicit 'When to enable options' section that maps specific technical conditions (React/Vue/Angular, 403 errors, delayed content loading) to parameter usage. Provides concrete decision trees for selecting js_render, premium_proxy, and other options. Includes practical JSON examples showing parameter combinations.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
TDQS
With only one tool, there is no possibility of confusion or overlap between tools. The single 'scrape' tool has a clear, distinct purpose of fetching webpage content.
There is only one tool name, so consistency is inherently perfect. The name 'scrape' follows a clear verb-based pattern appropriate for its function.
A single tool is too few for most server purposes, as it limits functionality and flexibility. While scraping is a focused domain, having only one tool feels thin and may not cover related needs like batch processing or error handling.
The tool covers basic webpage scraping with options for dynamic content and proxies, but there are notable gaps. Missing operations might include checking scrape status, managing sessions, or handling rate limits, which could lead to agent workarounds or failures in complex scenarios.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
One MCP for the Web. Easily search, crawl, navigate, and extract websites without getting blocked.…
Scrapingdog MCP — wraps Scrapingdog (scrapingdog.com), a proxy-based web
Firecrawl MCP — wraps the Firecrawl API (firecrawl.dev) for web
Turn any URL into clean Markdown and structured data. Scrape, crawl, search and extract.
Related MCP Servers
- AlicenseAqualityDmaintenanceMCP-native web scraping and search API for AI agents. Converts any URL to clean Markdown with 90% success rate, including Cloudflare-protected sites and JS SPAs. Real-time web search via Brave Search API. CAPTCHA solving built-in. 10 free scrapes/day.595MIT
- AlicenseNot gradedqualityFmaintenanceAn MCP server that extracts clean Markdown or HTML content from web pages by stripping away ads, navigation, and clutter. It offers tools to process URLs or raw HTML, returning structured metadata alongside the main article content.2MIT
- AlicenseAqualityBmaintenanceWeb extraction MCP server for AI agents. Extract structured data from any URL with built-in Cloudflare bypass, JavaScript rendering, and intelligent parsing. Returns clean markdown or JSON.57942MIT
- AlicenseNot gradedqualityAmaintenanceRemote MCP server for web scraping with anti-bot evasion. Provides stealth HTTP fetching, headless browser with Cloudflare bypass, CSS selectors, YouTube transcripts, and Markdown conversion.1MIT
Appeared in Searches
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/ZenRows/zenrows-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server