Skip to main content

Summary

The Google Maps MCP server provides comprehensive location services including geocoding, place search, directions, and autocomplete. Perfect for building location-aware assistants, navigation bots, and local business finders.

Authentication

This server requires a Google Maps API key. The key must have the following APIs enabled:
  1. Places API (for place search, details, autocomplete, nearby search)
  2. Geocoding API (for geocoding and reverse geocoding)
  3. Directions API (for routing and navigation)

Getting Your API Key

1

Go to Google Cloud Console

2

Create or Select a Project

Create a new project or select an existing one
3

Enable Required APIs

Enable Places API, Geocoding API, and Directions API for your project
4

Create API Key

Go to “Credentials” and create an API key. Add appropriate restrictions (HTTP referrers or IP addresses) for security.
5

Use in Requests

Include the key in your request header:
Important: Secure your API key by restricting it to specific domains, IP addresses, or API endpoints in the Google Cloud Console.

Use Cases

Finding Nearby Restaurants

User: “Find Italian restaurants near 123 Main St, Seattle” Tool Calls:
  1. geocode - Convert “123 Main St, Seattle” to coordinates
  2. nearby-search - Search for restaurants with type “italian_restaurant” near those coordinates
  3. get-place-details - Get full details for top results (hours, reviews, phone)
Result: List of Italian restaurants with ratings, hours, distance, and contact info

Getting Directions with Traffic

User: “How do I get from my office to the airport? I need to leave now.” Tool Calls:
  1. get-directions - Calculate route with mode: "driving" and departure_time: "now" for traffic estimates
Result: Turn-by-turn directions with current traffic conditions and estimated travel time

Location Autocomplete

User: “I’m trying to remember the full address… it’s something like ‘123 Mai’” Tool Calls:
  1. autocomplete-places - Get suggestions for “123 Mai” with types: "address"
Result: Complete address suggestions the user can select from

Available Tools

geocode

Convert an address or location name to geographic coordinates. Returns: Latitude/longitude coordinates, formatted address, place ID, and address components breakdown. Example:

reverse-geocode

Convert coordinates to a human-readable address. Returns: Multiple detail levels from specific street address to country. Example:

search-places

Search for places using natural language queries. Returns: List of places with names, addresses, ratings, open status, and place IDs. Common Place Types:
  • Food: restaurant, cafe, bar, bakery, meal_takeaway
  • Lodging: hotel, lodging, motel
  • Services: gas_station, parking, car_repair, hospital, pharmacy, bank, atm
  • Activities: gym, park, zoo, museum, movie_theater
  • Shopping: store, supermarket, shopping_mall
  • Transit: airport, train_station, bus_station, subway_station

get-place-details

Get comprehensive information about a specific place. Returns: Full place details including:
  • Name and business status
  • Complete address and coordinates
  • Rating, review count, and sample reviews
  • Contact info (phone, website)
  • Opening hours with current status
  • Price level
Example:

Find places of a specific type near coordinates. Returns: Places sorted by distance with ratings, open status, and distance from center point.
Use with geocode: If you have an address instead of coordinates, call geocode first to get lat/lon coordinates, then use those with nearby-search.

autocomplete-places

Get autocomplete suggestions for partial addresses or place names. Returns: Autocomplete suggestions with place IDs for detailed lookup. Type Filters:
  • geocode - All geocoding results
  • address - Precise street addresses
  • establishment - Businesses and points of interest
  • (regions) - Geographic regions (cities, states, countries)
  • (cities) - Cities only

get-directions

Get routes and turn-by-turn directions between locations. Returns:
  • Step-by-step directions with distances and times
  • Total distance and duration
  • Traffic information (if departure_time specified for driving)
  • Alternative routes (if requested)
  • Warnings and notices
Examples:
Traffic Estimates: Use departure_time: "now" with driving mode to get current traffic conditions and adjusted travel times.

Common Workflows

Finding a Place

1

Search

Use search-places with a descriptive query
2

Get Details

Use get-place-details with the place_id from the best match

Getting Directions

1

Calculate Route

Use get-directions with origin and destination (addresses work directly)
2

Add Traffic

Add departure_time: "now" for current traffic conditions (driving mode)

Location-Based Recommendations

1

Geocode Address

Use geocode to convert address to coordinates
2

Search Nearby

Use nearby-search with coordinates and desired type
3

Get Details (Optional)

Use get-place-details for top results

Tips & Best Practices

  • Include geographic context in search queries for better results (e.g., “pizza in downtown Seattle” vs “pizza”)
  • Use place_id from search results to get details - never guess or construct place IDs
  • Addresses work directly in get-directions - no need to geocode first
  • Check opening hours by day if relevant - hours vary by day of the week
  • Use departure_time with driving mode for traffic-aware travel estimates
  • Results are cached briefly - very recent changes may not appear immediately

API Reference

View the complete API specification for Google Maps MCP server endpoints