# OpenStreetMap [Health: Active]

**Category:** 🗺️ Location Services  
**Repository:** https://github.com/ni-c/osm-mcp  
**GitHub Stars:** 4  
**npm Downloads (last month):** 1032  
**Views:** 1  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/openstreetmap

## Description
Geocoding, walking/driving/cycling distances, route optimization, isochrones and POI search on OSM

## Tools
Capabilities this server exposes over MCP:

- **geocode** — Converts a place name or address into coordinates using OpenStreetMap. Returns matching places with lat/lon, a display label and the OSM id. Provider "nominatim" (default) is best for addresses; "photon" is typo-tolerant and better for fuzzy place names.
- **reverse_geocode** — Converts coordinates into the nearest address or place name (Nominatim).
- **route** — Calculates the real-world travel distance and time between two or more places, walking, driving or cycling, on OpenStreetMap data. Waypoints are visited in the given order. Set include_steps for a turn-by-turn summary. Use route_matrix to compare many pairs, optimize_route to reorder stops.
- **route_matrix** — Computes travel times and distances from every origin to every destination in one call — ideal for comparing options (e.g. 5 hotels against 3 sights). Cells are null where no route exists.
- **optimize_route** — Finds the best order to visit a set of stops (traveling-salesman optimization) and returns the optimized itinerary with total distance and time. With roundtrip (default) the tour returns to the first stop; without it the first stop is the start and the last stop the end.
- **isochrone** — Shows how far you can get from a place within a time or distance budget ("what is reachable in 15 minutes on foot?"). Returns a compact summary of the reachable area: bounding box and reach per compass direction. Give exactly one of minutes or kilometers.
- **find_nearby_pois** — Finds points of interest near a location, sorted by distance. Category shortcuts: restaurant, cafe, bar, pub, fast_food, ice_cream, hotel, hostel, guest_house, apartment, camp_site, attraction, museum, gallery, viewpoint, information, artwork, castle, monument, ruins, supermarket, bakery, convenience, pharmacy, hospital, doctors, police, atm, bank, fuel, charging_station, parking, toilets, drinking_water, bus_stop, train_station, tram_stop, ferry_terminal, bicycle_rental, car_rental, playground, park, beach, swimming_pool. Any other OSM tag works as "key" or "key=value" (e.g. "diet:vegan=yes"). Use poi_details for the full record of one result.
- **poi_details** — Fetches the full OpenStreetMap record of one element — all tags (opening hours, website, phone, …), coordinates and a map link. Takes an OSM id as returned by find_nearby_pois or geocode, e.g. "node/240109189".
- **suggest_meeting_point** — Suggests a fair place to meet for people starting from different locations: finds venues around the geographic midpoint and picks the one with the most balanced travel times for everyone.
- **straight_line_distance** — Great-circle ("as the crow flies") distance between two places. Instant and independent of any road network — use route for real travel distances.
- **map_link** — Generates openstreetmap.org links to open in a browser: a marker link for a single place, or a directions link when from and to are given. Provide either "place", or both "from" and "to".

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `npx` (confidence: high):

```json
"mcpServers": {
  "openstreetmap": {
    "command": "npx",
    "args": ["-y","osm-mcp"]
  }
}
```

## Documentation

## What OpenStreetMap MCP server does

OpenStreetMap MCP server gives MCP clients access to read-only travel-planning operations based on OpenStreetMap data. It exposes 11 tools for converting place names and addresses into coordinates, finding nearby points of interest, calculating travel distances and durations, and creating links to OpenStreetMap maps or directions.

The routing tools cover foot, car, and bicycle travel. An agent can calculate a route between multiple waypoints, request a matrix covering every origin and destination pair, or optimize the order of several stops. Isochrones describe the area reachable within a time or distance limit. A meeting-point tool can select a venue for two to eight people by balancing travel times.

POI searches can use categories or raw OSM tags and sort results by distance. After finding an element, `poi_details` can return fields such as opening hours, website, and phone number. Straight-line distance and map-link generation are calculated offline.

## How it works

The server communicates with MCP clients over stdio and calls external services over HTTPS. Nominatim or Photon handles geocoding, while OSRM handles routing, matrices, and trip optimization by default. Valhalla supplies isochrones, and Overpass supplies nearby-POI searches and OSM element details. OpenRouteService can replace the default routing, matrix, and isochrone backends when an API key is configured.

Requests to public services are rate-limited per service, responses are cached in memory, and Overpass requests are limited to two concurrent slots. The server can try another configured Overpass endpoint after a 429 or 5xx response. Its User-Agent is configurable and is sent to each service. These behaviors matter when deploying the OpenStreetMap MCP server against public endpoints or when using repeated agent lookups.

All exposed operations are read-only. The server does not provide tools for editing or uploading OpenStreetMap data.

## Setup and configuration

Running the OpenStreetMap MCP server requires Node.js 22 or newer and internet access to the configured public services. The configuration variables are optional, so the default endpoints can be used without an API key. Set `OSM_USER_AGENT` to provide an identifying User-Agent, especially when using Nominatim.

Useful endpoint variables include `NOMINATIM_BASE_URL`, `PHOTON_BASE_URL`, `OSRM_BASE_URL`, `OVERPASS_BASE_URL`, and `VALHALLA_BASE_URL`. `ORS_BASE_URL` selects the OpenRouteService endpoint, while `ORS_API_KEY` enables ORS for routes, matrices, and isochrones. The documented free ORS tier allows 2,000 directions per day and 40 requests per minute.

`OSM_CACHE_TTL` controls how long identical upstream responses remain in the in-memory cache; setting it to `0` disables caching. Tool registration can be reduced with `OSM_ALLOW_TOOLS`, including the `essential` preset or comma-separated names. `OSM_DENY_TOOLS` removes matching tools afterward, and wildcard entries can select tool families. Unknown filter entries stop startup rather than silently hiding a tool.

_Full upstream README: https://allmcps.com/mcp/openstreetmap/readme_

