# gsearch [Health: Active]

**Category:** 🔎 Search & Data Extraction  
**Repository:** https://github.com/RayenMlayeh/gsearch  
**GitHub Stars:** 10  
**Views:** 1  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/gsearch-2

## Description
Real Google Search for AI agents, over MCP. Self-hosted, no API key. Real URLs, AI Overview and People also ask as typed JSON. Uses a real Firefox (Camoufox) on your IP or any proxy.

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `uvx` (confidence: high):

```json
"mcpServers": {
  "gsearch": {
    "command": "uvx",
    "args": ["--from","gsearch-agent","gsearch"],
    "env": {
      "GSEARCH_PROXY": "",
      "GSEARCH_DATA_LIMIT_MB": "",
      "GSEARCH_ENV_FILE": ""
    }
  }
}
```

**Requires environment variables:** `GSEARCH_PROXY`, `GSEARCH_DATA_LIMIT_MB`, `GSEARCH_ENV_FILE` — the values above are empty placeholders; fill in real credentials before running (see the repository for what each one is for).

## Documentation

## What gsearch does

gsearch exposes Google Search to MCP-compatible agents without requiring a Google Search API key or hosted search account. A query can return organic results with titles, snippets, sites, and destination URLs, along with supported Google result features such as answer boxes, top stories, videos, the AI Overview, People also ask, and related searches.

The server also supports follow-up page retrieval. Agents can fetch a selected page, resolve Google’s redirect links for a result set, or read the text of the top pages together with search results. Responses use typed JSON, and web-derived strings are identified as untrusted content.

## How it works

A real Firefox instance based on Camoufox loads Google’s results page instead of making a plain HTTP request. The browser runs on the machine hosting gsearch, using that machine’s IP unless a proxy is configured. This approach is intended to handle Google’s JavaScript-driven pages and return the page elements exposed by the search result.

The server uses the MCP stdio pattern: an MCP client starts `gsearch-mcp` and communicates with it through the process. Search blocks are returned as structured errors when Google presents a block, including a suggested `retry_after_s` value, rather than being reported as an empty result set.

## Setup and configuration

Install the Python package with `uv tool install gsearch-agent` or `pipx install gsearch-agent`. Run `gsearch setup` once to download the browser, which requires roughly 1 GB, and to print an MCP configuration. The generated command can then be added to an MCP client. A `uvx` configuration is also available after fetching the browser with `uvx --from gsearch-agent gsearch setup`.

The documented client examples use Claude Desktop and Cursor. Claude Desktop stores the server entry in `claude_desktop_config.json`; Cursor accepts it in `~/.cursor/mcp.json` or a project-level `.cursor/mcp.json`.

Configuration can be passed through the MCP client’s environment block or a `.env` file. Set `GSEARCH_ENV_FILE` to the absolute path of that file. `GSEARCH_PROXY` accepts common HTTP, HTTPS, and SOCKS5 proxy formats, including credentials and session placeholders. `GSEARCH_DATA_LIMIT_MB` sets the data limit.

Without a proxy, the documented limit is at most 20 searches per hour on the local IP. Proxy use can provide another route, but traffic and proxy costs remain the operator’s responsibility.

## Tools and capabilities

- `google_search` performs a Google query and returns structured result data.
- `fetch_page` follows a result and retrieves the page selected by the agent.
- `resolve_links` resolves Google’s result redirects to destination URLs for a result set.
- `read_top` reads the text of the top result pages along with the search response.
- Search output can include organic results, answer boxes, top stories, videos, AI Overview, People also ask, and related searches.
- Structured block errors include retry timing when Google blocks a request.

## Limitations and notes

Google may rate-limit or block automated searches. The project reports that unproxied use is limited and warns that automated Google Search access may conflict with Google’s Terms of Service; operators should review the legal and responsible-use guidance before running live searches.

The browser download is large, and live searches depend on Google’s response, the configured IP or proxy, and the browser session. A proxy is optional, but proxy traffic can consume the configured data allowance. Search output is web content and should be treated as untrusted when passed to an agent or application.

The project is licensed under MIT and requires Python 3.12 or newer.

_Full upstream README: https://allmcps.com/mcp/gsearch-2/readme_

