MCP Google Custom Search Server
@alexatnordnet
About MCP Google Custom Search Server
An mcp server for searching against google custom search api
Config
Add this server to your MCP-compatible client using the configuration below.
{
"mcpServers": {
"mcp-google-custom-search-server": {
"command": "npx",
"args": [
"@modelcontextprotocol/inspector",
"node",
"build/index.js"
]
}
}
}Tools
No tools detected
Fetch the live tool list by running this server in a temporary sandbox using the button above.
Overview
What is MCP Google Custom Search Server?
A Model Context Protocol (MCP) server that enables Language Learning Models (LLMs) to perform web searches through Google's Custom Search API. It provides a standardized, type-safe interface compatible with Claude Desktop and other MCP clients.
How to use MCP Google Custom Search Server?
Install dependencies with npm install, create a .env file with your GOOGLE_API_KEY and GOOGLE_SEARCH_ENGINE_ID, then build (npm run build) and start (npm start) the server. For Claude Desktop integration, add a JSON configuration entry pointing to the built server and supplying the same environment variables.
Key features of MCP Google Custom Search Server
- Seamless integration with Google Custom Search API
- MCP-compliant server implementation with TypeScript
- Configurable search results (up to 10 per query)
- Formatted output with titles, URLs, and descriptions
- Input validation using Zod
- Error handling and validation
Use cases of MCP Google Custom Search Server
- Providing web search results to an LLM for answering queries
- Integrating real-time web data into conversational AI assistants
- Enabling dynamic fact-checking and research via MCP clients
FAQ from MCP Google Custom Search Server
What prerequisites are needed to run the server?
You need a Google Cloud Project with the Custom Search API enabled, an API key, and a Custom Search Engine ID. Locally, Node.js v18 or higher and npm are required.
How do I configure the server for Claude Desktop?
Add a JSON block in the Claude Desktop config file (typically ~/Library/Application Support/Claude/claude_desktop_config.json) under mcpServers with the command node, the absolute path to the built index.js, and the required GOOGLE_API_KEY and GOOGLE_SEARCH_ENGINE_ID environment variables.
How many results can the search tool return per query?
The optional numResults parameter defaults to 5 and can be set up to a maximum of 10 results per search.
What runtime and dependencies does the server require?
It runs on Node.js v18+ with npm, and depends on the Google Custom Search API and the Model Context Protocol libraries.
Does the server handle invalid input or errors?
Yes, it includes input validation via Zod and error handling for API failures and malformed requests.
Frequently asked questions
What prerequisites are needed to run the server?
You need a Google Cloud Project with the Custom Search API enabled, an API key, and a Custom Search Engine ID. Locally, Node.js v18 or higher and npm are required.
How do I configure the server for Claude Desktop?
Add a JSON block in the Claude Desktop config file (typically `~/Library/Application Support/Claude/claude_desktop_config.json`) under `mcpServers` with the command `node`, the absolute path to the built `index.js`, and the required `GOOGLE_API_KEY` and `GOOGLE_SEARCH_ENGINE_ID` environment variables.
How many results can the search tool return per query?
The optional `numResults` parameter defaults to 5 and can be set up to a maximum of 10 results per search.
What runtime and dependencies does the server require?
It runs on Node.js v18+ with npm, and depends on the Google Custom Search API and the Model Context Protocol libraries.
Does the server handle invalid input or errors?
Yes, it includes input validation via Zod and error handling for API failures and malformed requests.
Basic information
More Search MCP servers
Perplexity MCP Zerver
wysh3MCP web search using perplexity without any API KEYS
Brave Search MCP Server
mikechaoAn MCP Server implementation that integrates the Brave Search API, providing, Web Search, Local Points of Interest Search, Image Search, Video Search, News Search and LLM Context Search capabilities
DuckDuckGo Search MCP Server
nickclydeA Model Context Protocol (MCP) server that provides web search capabilities through DuckDuckGo, with additional features for content fetching and parsing.
SerpApi MCP Server
ilyazubSerpApi MCP Server for Google and other search engine results
G-Search MCP
jae-jaeA powerful MCP server for Google search that enables parallel searching with multiple keywords simultaneously.
Comments