Featured

Deploy OpenClaw in 60 seconds — 20% off logoDeploy OpenClaw in 60 seconds — 20% off

Launch OpenClaw on Hostinger in about 60 seconds and keep your agent live 24/7. Our referral link gives you 20% off, no coupon code needed.

Launch on Hostinger
Run your Hermes agent on Hostinger, fully managed logoRun your Hermes agent on Hostinger, fully managed

Launch Hermes on Hostinger in one click, fully managed, no VPS knowledge needed. Use code ZACAARON10 for 10% off.

Launch on Hostinger
Crawl and scrape any site into clean data, 10% off logoCrawl and scrape any site into clean data, 10% off

Firecrawl crawls and scrapes any site into clean markdown for your agent. Get 1,000 free credits, and new users get 10% off their first purchase.

Try Firecrawl free
6,000+ web scrapers for your AI agent, start free logo6,000+ web scrapers for your AI agent, start free

Apify gives your agent live web data: 6,000+ prebuilt scrapers and actors, MCP-ready. Sign up free with $5 in usage credits.

Try Apify free
One API to scrape, enrich, and extract the internet. logoOne API to scrape, enrich, and extract the internet.

Context.dev gives your agents a single API to scrape, enrich, and extract live web data — no proxies, no parsers, no maintenance.

Start building free
SetupClaw: done-for-you OpenClaw for founders & exec teams logoSetupClaw: done-for-you OpenClaw for founders & exec teams

White-glove OpenClaw for founders and exec teams (4–50+ employees): we install, harden, integrate your tools, and maintain it — secured from day one.

Get it set up for you
SEO data APIs for your agent, $1 free credit logoSEO data APIs for your agent, $1 free credit

DataForSEO gives your agent live access to SERP results, keyword data, backlinks, and on-page SEO data through one API. New accounts get a $1 credit, good for up to 20,000 keyword or backlink lookups.

Try DataForSEO free
Reach 48,000+ AI builders

A flat monthly placement in front of developers actively installing AI tools. No lock-in, cancel anytime.

Advertise here

Works with

Claude CodeClaude DesktopCursorVS CodeClineCodex CLIOpenClaw+ any MCP client

Install to Claude Code

This server doesn't publish a one-line install command. Follow the setup in the source repository.

Summary

MCP server for Claude Code that provides Google text search, web content extraction, and image search with dual-platform (Google Images + Pinterest) and AI visual analysis with quality scoring.

README.md

Google Search MCP Server v2.0.0

一个强大的 MCP (Model Context Protocol) 服务器,为 Claude Code 提供 Google 搜索和图片搜索能力。

✨ 特性

🔍 搜索功能

  • Google 文本搜索 - 自定义结果数量,支持多语言
  • 网页内容提取 - 智能过滤广告和导航
  • 批量提取 - 并行处理,速度提升 3x
  • 搜索+提取组合 - 一键深度内容检索

🖼️ 图片搜索 (核心功能)

  • 双平台搜索 - Google Images + Pinterest 并行搜索
  • 多模型 AI 视觉分析 - 支持 GLM-4.6V、GPT-4O、Claude 3.5 等
  • S/A/B/C 质量评分 - 基于来源和相似度的智能评分
  • 产品参考图搜索 - 非常适合电商、设计场景

🚀 性能优化

  • 浏览器池 - 单例复用,避免重复启动
  • 并行处理 - 批量操作并发执行
  • 模块化架构 - 代码清晰,易于维护

📦 安装

前置条件

  • Node.js >= 18.0.0
  • Claude Code

安装步骤

# 1. 克隆项目
git clone <repo-url>
cd google-search-mcp-v2

# 2. 安装依赖
npm install

⚙️ 配置

配置 Claude Code

编辑 ~/.claude.json,添加以下配置:

{
  "mcpServers": {
    "google-search": {
      "type": "stdio",
      "command": "node",
      "args": ["/你的路径/google-search-mcp-v2/src/index.js"]
    }
  }
}

重启 Claude Code 生效。

配置 AI 视觉分析 (可选)

设置环境变量以启用 AI 图片分析:

# 智谱 GLM (推荐,国内使用)
export GLM_API_KEY=your_api_key

# 或 OpenAI
export OPENAI_API_KEY=your_api_key

# 或 Anthropic Claude
export ANTHROPIC_API_KEY=your_api_key

# 指定使用的模型 (可选)
export VISION_MODEL=glm-4.6v  # 或 gpt-4o, claude-3.5-sonnet

💡 如果不配置 API Key,图片搜索会使用文件名作为关键词进行搜索(仍然可用)。

🛠️ MCP 工具

| 工具名 | 描述 | |--------|------| | google_search | Google 文本搜索 | | fetch_url | 提取单个网页内容 | | batch_fetch_urls | 批量提取多个网页 (并行) | | search_and_extract | 搜索并自动提取内容 | | search_by_image | 图片搜索 (双平台 + AI 分析 + 评分) |

💻 命令行使用

除了 MCP 模式,还支持命令行直接使用:

# 显示帮助
node src/index.js --help

# Google 搜索
node src/index.js "Node.js 教程"
node src/index.js "React hooks" 5

# 提取网页内容
node src/index.js --fetch https://example.com

# 批量提取
node src/index.js --batch "https://a.com,https://b.com"

# 搜索并提取
node src/index.js --extract "Python 入门" 3

# 图片搜索
node src/index.js --image ./product.jpg 10

📊 图片搜索评分系统

| 等级 | 分数范围 | 说明 | |------|----------|------| | 🏆 S | 85-100 | 顶级来源 (天猫国际、品牌官网) | | ⭐ A | 75-84 | 优质来源 (天猫、京东、亚马逊) | | ✓ B | 60-74 | 普通来源 (淘宝、Pinterest) | | ○ C | 0-59 | 其他来源 |

📁 项目结构

google-search-mcp-v2/
├── src/
│   ├── index.js          # 入口
│   ├── mcp-server.js     # MCP 协议处理
│   ├── cli.js            # 命令行模式
│   ├── config.js         # 配置管理
│   │
│   ├── browser/
│   │   └── pool.js       # 浏览器池 (单例复用)
│   │
│   ├── tools/
│   │   ├── google-search.js
│   │   ├── fetch-url.js
│   │   ├── search-extract.js
│   │   └── image-search.js
│   │
│   ├── image/
│   │   ├── google-images.js
│   │   ├── pinterest.js
│   │   └── scorer.js     # S/A/B/C 评分
│   │
│   ├── ai/
│   │   ├── models.js     # 视觉模型配置
│   │   └── vision.js     # AI 分析
│   │
│   └── utils/
│       └── logger.js
│
├── package.json
└── README.md

🔧 支持的 AI 模型

| 模型 | 环境变量 | 说明 | |------|----------|------| | GLM-4.6V | GLM_API_KEY | 智谱 AI,国内推荐 | | GLM-4V | GLM_API_KEY | 智谱 AI | | GPT-4O | OPENAI_API_KEY | OpenAI 最新视觉模型 | | GPT-4 Turbo | OPENAI_API_KEY | OpenAI | | Claude 3.5 Sonnet | ANTHROPIC_API_KEY | Anthropic |

📄 License

MIT

See related servers & alternatives →

Related MCP servers

Browse all →

Related guides

Hand-picked reading to help you choose and use Search servers.