MCP ExplorerExplorer

Mcp Google Search

@colatussoon 9 months ago
1 MIT
FreeCommunity
AI Systems
MCP server for Google searches using Custom Search API, formatted in Markdown.

Overview

What is Mcp Google Search

mcp-google-search is a Model Context Protocol (MCP) server that enables users to perform Google searches using the Custom Search API.

Use cases

Use cases include searching for specific topics, retrieving top results for queries, and integrating search capabilities into applications or services.

How to use

To use mcp-google-search, set up a virtual environment, install the necessary dependencies, configure your Google API credentials, and run the server using the command ‘python server.py’. You can also use it with MCP Inspector for development.

Key features

Key features include performing Google searches through the Custom Search API, returning results formatted in Markdown, and allowing users to limit the number of results as requested.

Where to use

mcp-google-search can be used in various fields such as research, web development, and any application requiring search functionalities integrated with Google.

Content

Google Search MCP Server

A Model Context Protocol (MCP) server that allows you to perform Google searches using the Custom Search API.

Features

  • Performs Google searches through the Custom Search API
  • Returns results formatted in Markdown
  • Limits the number of results as requested

Prerequisites

  • Python 3.8+
  • Google Custom Search API credentials
  • Custom Search Engine ID (CSE ID)

Installation

  1. Create a virtual environment:
python -m venv venv
source venv/bin/activate  # On Windows use: venv\Scripts\activate
  1. Install dependencies:
pip install mcp httpx python-dotenv
  1. Configure your credentials:
cp .env.example .env
  1. Edit the .env file with your credentials:
GOOGLE_API_KEY=your_api_key_here
GOOGLE_CSE_ID=your_cse_id_here

How to Use

Direct execution

python server.py

Development with MCP Inspector

mcp dev server.py

Installation in Claude Desktop

mcp install server.py --name "Google Search"

Usage with Claude

Once the server is running and connected to Claude, you can perform searches with:

Search Google for "artificial intelligence and ethics"

Or specify the number of results:

Find the top 3 results for "machine learning frameworks"

Getting Google Credentials

  1. Create a Google API key in the Google Cloud Console
  2. Enable the Custom Search API
  3. Create a custom search engine at Custom Search Engine
  4. Get your search engine ID (cx)

License

MIT

Tools

No tools

Comments

Recommend MCP Servers

View All MCP Servers