Get the FREE Ultimate OpenClaw Setup Guide →

Google-Search

MCP server from kongyo2/Google-Search-MCP

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio kongyo2-google-search-mcp npm run start \
  --env PORT="3000" \
  --env NODE_ENV="production"

How to use

This MCP server enhances Google search capabilities by exposing a single MCP tool named 'search' that can perform advanced Google queries through an MCP interface. It includes support for complex query handling, language and region targeting, safe search levels, and time-range filters. The server incorporates anonymization and anti-detection features, including rotating user agents, dynamic headers, session randomization, and smart retry logic to improve reliability in the face of rate limiting. Use the provided MCP 'search' tool to construct queries and retrieve structured results, with robust error handling and logging for debugging and monitoring.

To use it, connect to the MCP server through your MCP client (e.g., Claude Desktop) and invoke the 'search' tool with parameters such as query, limit, language, region, safeSearch, and timeRange. Example usage shows a request payload with a query and optional controls for limit, language, region, safeSearch, and timeRange. The server will return a list of results with validated URLs and content when available, along with status information and error messages if something goes wrong.

How to install

Prerequisites:

  • Node.js (recommended LTS) and npm installed on your system
  • Basic familiarity with MCP tooling and JSON configuration
  1. Install the MCP server package
  • Using npm (recommended): npm install --save @kongyo2/google-search-mcp
  1. Install and configure your MCP client environment (example using Claude Desktop):
  • Ensure you have Claude Desktop installed
  • Add an MCP server entry pointing to this package (see mcp_config example in this document)
  1. Start the server
  • If you are using the standard npm start script provided by the package, run: npm run start
  • For development, you can run: npm run dev
  1. Verify operation
  • Check the server logs to ensure it starts correctly and listens on the configured port (default 3000).
  • From your MCP client, invoke the 'search' tool with a test query to confirm results are returned.

Additional notes

Notes and tips:

  • This is an experimental server that uses web scraping against Google; rate limiting and blocking can occur. Use with caution and prefer official APIs for production workloads.
  • You can tune request behavior via environment variables and server configuration (e.g., timeouts, delays, and retry strategies).
  • The MCP tool 'search' supports: query (required), limit (1-10, default 5), language, region, safeSearch, and timeRange. Consider adjusting these to balance result quality and reliability.
  • Review the provided logging to diagnose issues related to parsing, network failures, or anti-scraping measures.
  • If your deployment requires production-grade reliability, consider using established alternatives (DuckDuckGo MCP, Bing Search API, Google Custom Search API, or SearXNG) as recommended in the README.

Related MCP Servers

Sponsor this space

Reach thousands of developers