Google Search MCP Server logo

Google Search MCP Server

by moritalous

This project is a Model Context Protocol (MCP) server that provides Google Search API functionality to AI assistants. It allows AI assistants to perform web searches using the Google Search API.

View on GitHub

Last updated: N/A

What is Google Search MCP Server?

The Google Search MCP Server is a tool that enables AI assistants to perform web searches using the Google Search API. It uses Gradio and MCP to provide an interface between the AI assistant and the Google Search API.

How to use Google Search MCP Server?

To use the server, first clone the repository, install the dependencies using pip install -e ., and set the environment variables for the Google Custom Search Engine ID and Google API key. Then, start the server by running python app.py. This will launch a Gradio interface that functions as an MCP server.

Key features of Google Search MCP Server

  • Web search using the Google Search API

  • Returns search results in JSON format

  • Retrieves up to 20 search results

  • Integration with AI assistants via MCP

Use cases of Google Search MCP Server

  • Enabling AI assistants to answer questions using up-to-date web information

  • Providing context to AI assistants based on web search results

  • Automating web research tasks through AI assistants

  • Integrating web search functionality into AI-powered applications

FAQ from Google Search MCP Server

What is the maximum query length?

The search query should be a maximum of 400 characters and 50 words.

What is the maximum number of results I can retrieve?

You can retrieve between 1 and 20 search results.

What is MCP?

MCP stands for Model Context Protocol, a protocol used for communication between AI models and external tools.

What Python version is required?

Python 3.12 or higher is required.

How do I set up the environment variables?

Copy the .env.sample file to .env and edit the .env file to include your Google Custom Search Engine ID and Google API key.