nearby-search-mcp

MCP.Pizza Chef: kukapay

NearbySearch MCP Server enables location-based place searches using IP detection and Google Places API. It provides a simple interface to find nearby places by keyword and type filters within a customizable radius. Requires Python 3.10+, Google Cloud API key, and internet connection. Ideal for integrating real-time location context into LLM workflows.

Use This MCP server To

Detect user location via IP for contextual queries Search nearby restaurants, shops, or services by keyword Filter nearby places by type for targeted results Integrate location-aware search into chatbots or assistants Provide real-time local recommendations in apps Enable geographic context in AI-driven workflows

README

NearbySearch MCP Server

An MCP server for nearby place searches with IP-based location detection.

GitHub License GitHub Last Commit Python Version

Features

  • IP-based Location Detection: Uses ipapi.co to determine your current location
  • Google Places Integration: Searches for nearby places based on keywords and optional type filters
  • Simple Interface: Single tool endpoint with customizable radius

Requirements

  • Python 3.10+
  • Google Cloud Platform API Key with Places API enabled
  • Internet connection

Installation

  1. Clone the repository:
git clone https://github.com/kukapay/nearby-search-mcp.git
cd nearby-search-mcp
  1. Install dependencies:
# Using uv (recommended)
uv add "mcp[cli]" httpx python-dotenv

# Or using pip
pip install mcp httpx python-dotenv
  1. Client Configuration
{
  "mcpServers": {
    "nearby-search": {
      "command": "uv",
      "args": ["--directory", "path/to/nearby-search-mcp", "run", "main.py"],
      "env": {
        "GOOGLE_API_KEY": "your google api key"
      }
    }
  }
}

Usage

Running the Server

  • Development Mode (with MCP Inspector):
mcp dev main.py
  • Install in Claude Desktop:
mcp install main.py --name "NearbySearch"
  • Direct Execution:
python main.py

Available Endpoints

Tool: search_nearby

  • Searches for places near your current location
  • Parameters:
    • keyword (str): What to search for (e.g., "coffee shop")
    • radius (int, optional): Search radius in meters (default: 1500)
    • type (str, optional): Place type (e.g., "restaurant", "cafe")

License

This project is licensed under the MIT License - see the LICENSE file for details.

nearby-search-mcp FAQ

How does the NearbySearch MCP server detect location?
It uses the ipapi.co service to determine the user's current location based on their IP address.
What APIs does this MCP server integrate with?
It integrates with the Google Places API to perform nearby place searches.
What are the requirements to run this MCP server?
Requires Python 3.10 or higher, a Google Cloud Platform API key with Places API enabled, and an internet connection.
How customizable is the search radius?
The search radius is customizable via the server's single tool endpoint parameters.
Can I filter search results by place type?
Yes, you can apply optional type filters to narrow down search results.
Is this MCP server suitable for real-time applications?
Yes, it supports real-time location detection and place searching for dynamic workflows.
How do I install and set up the NearbySearch MCP server?
Clone the GitHub repo, install dependencies with uv or pip, and configure your Google API key as per instructions.