home / mcp / openstreetmap mcp server

OpenStreetMap MCP Server

An OpenStreetMap MCP server implementation that enhances LLM capabilities with location-based services and geospatial data.

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "jagan-shanmugam-open-streetmap-mcp": {
      "command": "uvx",
      "args": [
        "osm-mcp-server"
      ]
    }
  }
}

You are using an OpenStreetMap MCP Server that augments language models with geospatial data and location-based capabilities. It lets you geocode addresses, find nearby places, get directions, analyze neighborhoods, locate EV charging, and more, directly through your MCP client. This guide walks you through practical usage, installation, and important notes so you can start querying maps and location data with your LLM workflows.

How to use

Connect your MCP client to the OSM MCP Server and begin invoking tools to access OpenStreetMap data. You can geocode text queries, reverse geocode coordinates, search for places by category, and request turn‑by‑turn directions between locations. You can also explore neighborhoods, identify optimal meeting points for multiple people, and locate parking facilities, schools, and EV charging stations. Use the client’s tooling to pass clear queries to the server and handle the structured results returned from the geospatial tools.

How to install

Prerequisites: ensure you have Python installed for package installation and runtime, and have a suitable environment to run MCP servers (CLI access with Python and a capable console). If you plan to run via local development tooling, you may also rely on a standard MCP runtime like uvx/uv.

Step 1: Install the package in development mode

pip install -e .

Step 2: Start the server using the MCP runtime configuration shown in the examples below. You will run the same server executable for local testing.

osm-mcp-server

Step 3: Verify the server is listening for MCP requests on standard input/output. Your MCP client can now invoke the available tools.

Configuration examples

Two example MCP runtime configurations are provided for running the server locally. Use the one that matches your environment.

"mcpServers": {
  "osm_mcp": {
    "command": "uvx",
    "args": [
      "osm-mcp-server"
    ]
  }
}

Additional local runtime configurations

If you are using an unpublished or development setup, you can run the server with a directory reference and an explicit run command.

"mcpServers": {
  "osm_mcp": {
    "command": "uv",
    "args": [
      "--directory",
      "/path/to/osm-mcp-server",
      "run",
      "osm-mcp-server"
    ]
  }
}

Notes on testing with clients

You can validate functionality by using example clients included with the project or by building your own client to invoke tools like geocode_address, find_nearby_places, and get_route_directions. Ensure your client connects through the MCP protocol and handles the structured results returned by each tool.

Security and best practices

Run the server in a controlled environment and restrict access to trusted MCP clients. When exposing a hostname or URL for remote testing, use secure channels and authenticated endpoints. Do not publish internal paths or credentials in shared logs or unauthenticated channels.

Troubleshooting

If the server fails to start, verify that the runtime command and arguments exactly match the configuration. Check that Python dependencies are installed (pip install -e .) and that the environment supports stdio-based MCP servers. For debugging, consider using the MCP Inspector tool to observe tool invocations and data flow.

Available tools

geocode_address

Convert a textual address or place name into geographic coordinates (latitude and longitude).

reverse_geocode

Convert geographic coordinates into a human-readable address.

find_nearby_places

Discover points of interest near a given location, within a specified radius or bounding area.

get_route_directions

Retrieve turn-by-turn directions between two locations.

search_category

Search for places belonging to a specific category within a defined area.

suggest_meeting_point

Suggest optimal meeting points for multiple people based on location data and constraints.

explore_area

Provide comprehensive data about a neighborhood, including points of interest and amenities.

find_schools_nearby

Locate educational institutions near a location.

analyze_commute

Evaluate and compare commuting options between home and work.

find_ev_charging_stations

Locate EV charging stations with filtering by connector type and power.

analyze_neighborhood

Assess neighborhood livability for real estate decisions.

find_parking_facilities

Find parking options near a destination, including availability and fees.