Returns web search results from the Google Custom Search API so agents can search the web.
Setup
Choose your client, copy the config, then fill in any required environment variables.
claude mcp add google-custom-search --env GOOGLE_API_KEY='<GOOGLE_API_KEY>' --env GOOGLE_SEARCH_ENGINE_ID='<GOOGLE_SEARCH_ENGINE_ID>' -- npx -y @adenot/mcp-google-search~/.codex/config.toml
[mcp_servers.google-custom-search]
command = "npx"
args = ["-y", "@adenot/mcp-google-search"]
env = { GOOGLE_API_KEY = "<GOOGLE_API_KEY>", GOOGLE_SEARCH_ENGINE_ID = "<GOOGLE_SEARCH_ENGINE_ID>" }
# codex mcp add google-custom-search --env GOOGLE_API_KEY='<GOOGLE_API_KEY>' --env GOOGLE_SEARCH_ENGINE_ID='<GOOGLE_SEARCH_ENGINE_ID>' -- npx -y @adenot/mcp-google-search~/.cursor/mcp.json
{
"mcpServers": {
"google-custom-search": {
"command": "npx",
"args": [
"-y",
"@adenot/mcp-google-search"
],
"env": {
"GOOGLE_API_KEY": "<GOOGLE_API_KEY>",
"GOOGLE_SEARCH_ENGINE_ID": "<GOOGLE_SEARCH_ENGINE_ID>"
}
}
}
}.vscode/mcp.json
{
"servers": {
"google-custom-search": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@adenot/mcp-google-search"
],
"env": {
"GOOGLE_API_KEY": "<GOOGLE_API_KEY>",
"GOOGLE_SEARCH_ENGINE_ID": "<GOOGLE_SEARCH_ENGINE_ID>"
}
}
}
}~/.gemini/settings.json
{
"mcpServers": {
"google-custom-search": {
"command": "npx",
"args": [
"-y",
"@adenot/mcp-google-search"
],
"env": {
"GOOGLE_API_KEY": "<GOOGLE_API_KEY>",
"GOOGLE_SEARCH_ENGINE_ID": "<GOOGLE_SEARCH_ENGINE_ID>"
}
}
}
}claude_desktop_config.json
{
"mcpServers": {
"google-custom-search": {
"command": "npx",
"args": [
"-y",
"@adenot/mcp-google-search"
],
"env": {
"GOOGLE_API_KEY": "<GOOGLE_API_KEY>",
"GOOGLE_SEARCH_ENGINE_ID": "<GOOGLE_SEARCH_ENGINE_ID>"
}
}
}
}.trae/mcp.json
{
"mcpServers": {
"google-custom-search": {
"command": "npx",
"args": [
"-y",
"@adenot/mcp-google-search"
],
"env": {
"GOOGLE_API_KEY": "<GOOGLE_API_KEY>",
"GOOGLE_SEARCH_ENGINE_ID": "<GOOGLE_SEARCH_ENGINE_ID>"
}
}
}
}Environment variables
GOOGLE_API_KEYGOOGLE_SEARCH_ENGINE_ID
Replace the placeholders with your own credentials and keep them out of version control.