MCP Web Reader logo

MCP Web Reader

Community
zacfire

让Claude等大语言模型轻松获取和解析任何网页内容,并转化为干净的Markdown。支持双引擎、批量处理,增强AI互联网信息处理能力。

Publisherzacfire
Repositorymcp-web-reader
LanguageTypeScript
Forks
10
Stars
46
Available tools
0
Transport typestdio
Categories
Links
  • Connect tools to AI workflows

    MCP Web Reader exposes MCP capabilities that can be used by compatible AI clients and agents.

  • 0 available tools

    Browse the callable actions below, including names and descriptions when provided by the server.

  • Ready-to-copy setup

    Use the installation snippets to configure this server in your preferred MCP client.

  • Open source signals

    46 stars and 10 forks from the linked repository.

MCP Web Reader

一个强大的 MCP (Model Context Protocol) 服务器,让 Claude 和其他大语言模型能够读取和解析网页内容。支持突破访问限制,轻松获取微信文章、时代杂志等受保护内容。

功能特点

  • 🚀 三引擎支持:集成 Jina Reader API、本地解析器和 Playwright 浏览器
  • 🔄 智能降级:Jina Reader → 本地解析 → Playwright 浏览器三层自动切换
  • 🌐 突破限制:使用 Playwright 处理 Cloudflare、验证码等访问限制
  • 📦 批量处理:支持同时获取多个 URL
  • 🎯 灵活控制:可选择强制使用特定解析方式
  • 📝 Markdown 输出:自动转换为清晰的 Markdown 格式

安装

方法 1:从源码安装

bash
# 克隆仓库
git clone https://github.com/zacfire/mcp-web-reader.git
cd mcp-web-reader

# 安装依赖
npm install

# 构建项目
npm run build

# 安装 Playwright 浏览器(必需)
npx playwright install chromium

方法 2:使用 npm 安装(如果已发布)

bash
npm install -g mcp-web-reader

配置

在 Claude Desktop 的配置文件中添加:

Windows: %APPDATA%\Claude\claude_desktop_config.json

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

json
{
  "mcpServers": {
    "web-reader": {
      "command": "node",
      "args": ["/absolute/path/to/mcp-web-reader/dist/index.js"]
    }
  }
}

使用方法

配置完成后,在 Claude 中可以使用以下命令:

  1. 智能获取(推荐)

    • "请获取 https://example.com 的内容"
    • 自动三层降级:Jina Reader → 本地解析 → Playwright 浏览器
  2. 批量获取

    • "请获取这些网页:[url1, url2, url3]"
    • 每个URL都享受智能降级策略
  3. 强制使用 Jina Reader

  4. 强制使用本地解析

  5. 强制使用浏览器模式

    • "使用浏览器获取 https://example.com"
    • 直接跳过其他方式,适用于确定有访问限制的网站

支持的受限网站类型

✅ 微信公众号文章 - 自动绕过访问限制
✅ 时代杂志、纽约时报 - 突破付费墙和地区限制
✅ Cloudflare 保护网站 - 通过真实浏览器绕过检测
✅ 需要 JavaScript 渲染的页面 - 完整执行页面脚本
✅ 有验证码/人机验证的网站 - 模拟真实用户行为

工具列表

  • fetch_url - 智能获取(三层降级:Jina → 本地 → Playwright)
  • fetch_url_with_jina - 强制使用 Jina Reader
  • fetch_url_local - 强制使用本地解析器
  • fetch_url_with_browser - 强制使用 Playwright 浏览器(突破访问限制)
  • fetch_multiple_urls - 批量获取多个 URL

技术架构

智能降级策略

用户请求 URL
    ↓
1. Jina Reader API (最快,成功率高)
    ↓ 失败
2. 本地解析器 (Node.js + JSDOM)
    ↓ 检测到访问限制
3. Playwright 浏览器 (真实浏览器,突破限制)

访问限制检测

自动识别以下情况并启用浏览器模式:

  • HTTP 状态码:403, 429, 503, 520-524
  • 错误关键词:Cloudflare, CAPTCHA, Access Denied, Rate Limit
  • 内容关键词:Security Check, Human Verification

开发

bash
# 开发模式(自动重新编译)
npm run dev

# 构建
npm run build

# 测试运行
npm start

# 安装浏览器二进制文件(首次使用必需)
npx playwright install chromium

性能优化

  • ⚡ 浏览器实例复用 - 避免重复启动开销
  • 🚫 资源过滤 - 阻止图片、样式表等不必要加载
  • 🎯 智能选择 - 优先使用快速方法,必要时才用浏览器
  • 💾 优雅关闭 - 正确清理浏览器资源

贡献

欢迎提交 Pull Request!

许可证

MIT License

Installation

TypingMind
{
  "mcpServers": {
    "mcp-web-reader": {
      "command": "node",
      "args": [
        "/absolute/path/to/mcp-web-reader/dist/index.js"
      ]
    }
  }
}

Use MCP Web Reader MCP with multiple AI models

TypingMind connects MCP tools at the workspace level, so once MCP Web Reader is connected, you can use it with different AI models in TypingMind instead of setting it up separately for each model. This MCP runs locally through the TypingMind MCP connector on your device.

Setup guide to use the local connector

Use this when the MCP server needs access to local files, apps, or private resources on your computer.

1

Open the MCP settings

In TypingMind, go to Settings, Advanced Settings, then Model Context Protocol and choose Setup Connector.

  1. Open TypingMind in your browser.
  2. Click the Settings icon.
  3. Go to Advanced Settings.
  4. Open the Model Context Protocol section.
  5. Click Setup Connector and choose This Device.
TypingMind MCP connector setup screen with This Device selected
2

Run the connector command

Choose This Device, copy the command from TypingMind, and run it in Terminal. Keep the process running while you use MCP.

  1. Copy the setup command shown by TypingMind.
  2. Open Terminal on macOS or Windows Terminal on Windows.
  3. Paste and run the command.
  4. Approve the package install if Terminal asks you to proceed.
  5. Keep the Terminal window running while using MCP tools.
3

Add MCP Web Reader as a server

When the connector status is Ready, click Edit Servers and paste the MCP server configuration.

  1. Wait until the connector status shows Ready.
  2. Click Edit Servers.
  3. Paste the MCP Web Reader MCP server configuration.
  4. Save the server list.
  5. Refresh if you want to confirm the connector is still ready.
TypingMind MCP settings showing active server and Edit Servers button
{
  "mcpServers": {
    "mcp-web-reader": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-web-reader"
      ]
    }
  }
}
4

Use it across models

Save the server list, open Plugins, enable the MCP Web Reader MCP tools, then select any supported AI model in TypingMind and use the tools in chat or assign them to an AI agent.

  1. Open the Plugins page in TypingMind.
  2. Enable the MCP Web Reader MCP tools.
  3. Start a chat and choose the AI model you want to use.
  4. Use the MCP tools in chat or assign them to an AI agent.
  5. Switch to another AI model whenever needed without reconnecting MCP.
TypingMind chat using enabled MCP tools with a selected AI model
Can you use MCP Web Reader to help me with this task?
MCP Web Reader
Sure. I read it.
Here is what I found using MCP Web Reader.

Frequently asked questions

What is the MCP Web Reader MCP server used for?

MCP Web Reader is an MCP server that lets compatible AI clients connect to external tools and context. In TypingMind, you can add this MCP server once and make its tools available in your AI workspace.

Can I use MCP Web Reader MCP with multiple AI models in TypingMind?

Yes. TypingMind connects MCP tools at the workspace level, so you can use MCP Web Reader with different AI models such as Claude, ChatGPT, Gemini, or other models you have configured in TypingMind without setting up the MCP server separately for each model.

Why use MCP Web Reader MCP with TypingMind?

TypingMind is one of the best frontends for LLM chat because it brings multiple AI models, prompts, plugins, AI agents, API keys, and MCP tools into one workspace. With MCP Web Reader connected, you can use its MCP tools across your preferred models while keeping your chat workflow organized in TypingMind.

How do I connect MCP Web Reader MCP to TypingMind?

MCP Web Reader runs through the TypingMind local MCP connector. This is best when the MCP server needs access to local files, desktop apps, command-line tools, or private resources on your computer.

What tools does MCP Web Reader MCP provide in TypingMind?

MCP Web Reader exposes MCP capabilities that can be enabled from the TypingMind Plugins page and used in chat or assigned to AI agents.

Do I need to share my API keys with TypingMind to use MCP Web Reader MCP?

No. TypingMind is local-first and lets you keep your model providers, API keys, prompts, and MCP configuration under your control. If MCP Web Reader requires authentication, add the required headers, OAuth settings, or local configuration for that MCP server when you create the connection.

Related MCP Servers

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇