The MCP Google Map Server is a Model Context Protocol (MCP) implementation that provides comprehensive Google Maps API functionality for LLMs. This server acts as a bridge between language models and Google Maps services, enabling location-based queries, geocoding, directions, and more.
You can install the MCP Google Map Server globally using npm:
npm install -g @cablate/mcp-google-map
Once installed, you can start the server by running:
mcp-google-map
For seamless integration with Dive Desktop:
{
"mcpServers": {
"google-map": {
"command": "npx",
"args": ["-y", "@cablate/mcp-google-map"],
"env": {
"GOOGLE_MAPS_API_KEY": "your_api_key"
},
"enabled": true
}
}
}
Before using the server, you need to set up your Google Maps API credentials:
export GOOGLE_MAPS_API_KEY="your_api_key_here"
Search for places near a specific location with customizable parameters.
Usage example:
Tool: search_nearby
Parameters: location, radius, type, keyword
Get comprehensive information about a specific place.
Usage example:
Tool: get_place_details
Parameters: place_id
Convert a text address to geographic coordinates.
Usage example:
Tool: maps_geocode
Parameters: address
Convert coordinates to a human-readable address.
Usage example:
Tool: maps_reverse_geocode
Parameters: latitude, longitude
Calculate distances and travel times between multiple points.
Usage example:
Tool: maps_distance_matrix
Parameters: origins, destinations, mode
Get detailed step-by-step directions between two points.
Usage example:
Tool: maps_directions
Parameters: origin, destination, mode
Retrieve elevation data for specific locations.
Usage example:
Tool: maps_elevation
Parameters: locations
When using direction and distance tools, you can specify the following travel modes:
There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json
file so that it is available in all of your projects.
If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json
file.
To add a global MCP server go to Cursor Settings > MCP and click "Add new global MCP server".
When you click that button the ~/.cursor/mcp.json
file will be opened and you can add your server like this:
{
"mcpServers": {
"cursor-rules-mcp": {
"command": "npx",
"args": [
"-y",
"cursor-rules-mcp"
]
}
}
}
To add an MCP server to a project you can create a new .cursor/mcp.json
file or add it to the existing one. This will look exactly the same as the global MCP server example above.
Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.
The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.
You can also explictly ask the agent to use the tool by mentioning the tool name and describing what the function does.