# gsearch

This MCP server gives an AI agent Google Search results with resolved URLs, AI Overview, and People also ask in JSON. Use it when Google’s index matters.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 8
- Author: RayenMlayeh
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/RayenMlayeh/gsearch
- Updated: 2026-10-18
- HTML: https://affpapa.org/en/nevibecode/mcp/gsearch

## What it does

gsearch exposes Google Search through the MCP tool `google_search`. The agent receives result links with their actual destinations, plus AI Overview, People also ask, and related searches as JSON. It runs on your machine with the Camoufox browser and does not require an API key.

Setup uses Python 3.12+ and `uvx`; `gsearch setup` fetches the browser, which is about `~1 GB`. Without a proxy, searches use your own IP and are limited to 20 per hour. Automated Google access may breach Google’s Terms of Service, so that legal risk belongs with the person running the server.

## Requirements
- Needs: Python and uv (commands run via uvx)
- Environment variables: `GSEARCH_PROXY`, `GSEARCH_DATA_LIMIT_MB` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add --env GSEARCH_PROXY=<GSEARCH_PROXY> --env GSEARCH_DATA_LIMIT_MB=<GSEARCH_DATA_LIMIT_MB> --transport stdio gsearch -- uvx gsearch-agent
```
Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from gsearch-agent <command>

### Codex

**Platform CLI**
```bash
codex mcp add gsearch --env GSEARCH_PROXY=<GSEARCH_PROXY> --env GSEARCH_DATA_LIMIT_MB=<GSEARCH_DATA_LIMIT_MB> -- uvx gsearch-agent
```
Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from gsearch-agent <command>

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "gsearch": {
            "command": "uvx",
            "args": [
                "gsearch-agent"
            ],
            "env": {
                "GSEARCH_PROXY": "<GSEARCH_PROXY>",
                "GSEARCH_DATA_LIMIT_MB": "<GSEARCH_DATA_LIMIT_MB>"
            }
        }
    }
}
```
Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from gsearch-agent <command>

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "gsearch": {
            "type": "stdio",
            "command": "uvx",
            "args": [
                "gsearch-agent"
            ],
            "env": {
                "GSEARCH_PROXY": "<GSEARCH_PROXY>",
                "GSEARCH_DATA_LIMIT_MB": "<GSEARCH_DATA_LIMIT_MB>"
            }
        }
    }
}
```
Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from gsearch-agent <command>

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add -e GSEARCH_PROXY=<GSEARCH_PROXY> -e GSEARCH_DATA_LIMIT_MB=<GSEARCH_DATA_LIMIT_MB> gsearch uvx gsearch-agent
```
Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from gsearch-agent <command>

## When to use it
- search Google’s own index
- return destination URLs instead of redirect links
- give an agent AI Overview data
- collect People also ask questions
- filter results to a domain and time range

## Example prompts
- Search Google for what asyncio is and return the first three links.
- Show what people ask about asyncio in People also ask.
- Find asyncio pages on `python.org` from the past year.

## Similar
- [agent-browser](https://affpapa.org/en/nevibecode/mcp/agent-browser.md) — MCP server · ★ 14
- [google-search](https://affpapa.org/en/nevibecode/skills/google-search.md) — skill · 3800 installs
- [HasData Google Search (SERP)](https://affpapa.org/en/nevibecode/mcp/hasdata-google-search-serp.md) — MCP server · ★ 17
- [scraping-google-search-results](https://affpapa.org/en/nevibecode/skills/scraping-google-search-results.md) — skill · 759 installs
- [google-search-browser-use](https://affpapa.org/en/nevibecode/skills/google-search-browser-use.md) — skill · 1900 installs
- [google-search-agent-teneo](https://affpapa.org/en/nevibecode/skills/google-search-agent-teneo.md) — skill · 509 installs

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
