OpenStreetMap Nominatim drop-in replacement

The public Nominatim instance asks for at most one request per second and no heavy use. osm.mygeocode.com speaks the same search and reverse interface, in JSON, JSONv2 and GeoJSON formats, with a quota you can actually plan around.

Change one hostname

Original host
  • nominatim.openstreetmap.org
Use insteadosm.mygeocode.com
Key parameterNone on the original. Add key=... to use your account, or whitelist your server IPs. Or send nothing and use the free 2,500 a day.
Before
curl "https://nominatim.openstreetmap.org/search?q=Brandenburg+Gate+Berlin&format=json&addressdetails=1"
After
curl "https://osm.mygeocode.com/search?q=Brandenburg+Gate+Berlin&format=json&addressdetails=1"

Why people move

The public Nominatim server is a shared resource with a strict usage policy. Running your own is a full-time job. This is the same interface without either problem.

Try it before you sign up for anything. Requests to osm.mygeocode.com count toward the same 2,500 a day you get on our own endpoints, with no key and no account. Above that, credits at $0.001 per request or €50 a month unlimited. Signing up takes an email address and nothing else.

See pricing Sign up with an email

Endpoints

Path on osm.mygeocode.comWhat it doesBacked by
/search?q=...&format=jsonFree-form searchForward geocoding
/search?street=...&city=...&country=...&format=jsonStructured searchForward geocoding
/reverse?lat=...&lon=...&format=jsonReverseReverse geocoding

Example response

This is what the request above returns. Field names, nesting and types follow Nominatim (OSM). Only the data behind them is ours.

Response from osm.mygeocode.com
[
  {
    "place_id": 2384719,
    "licence": "Data by My Geocode, https://mygeocode.com/terms/",
    "osm_type": "way",
    "osm_id": 518071791,
    "lat": "52.5162746",
    "lon": "13.3777041",
    "class": "tourism",
    "type": "attraction",
    "place_rank": 30,
    "importance": 0.8317,
    "addresstype": "tourism",
    "name": "Brandenburger Tor",
    "display_name": "Brandenburger Tor, Pariser Platz, Mitte, Berlin, 10117, Deutschland",
    "address": {
      "tourism": "Brandenburger Tor",
      "road": "Pariser Platz",
      "suburb": "Mitte",
      "borough": "Mitte",
      "city": "Berlin",
      "state": "Berlin",
      "postcode": "10117",
      "country": "Deutschland",
      "country_code": "de"
    },
    "boundingbox": ["52.5161073", "52.5164414", "13.3775375", "13.3778623"]
  }
]

Details and differences

  • No key is needed for the free 2,500 requests a day. To bill beyond that, add key=... to the query or whitelist your IP. Nominatim clients that cannot send a key work fine with whitelisting.
  • osm_type and osm_id are populated when the result comes from OpenStreetMap data and are 0 otherwise.
  • format=json, format=jsonv2, format=geojson and format=geocodejson are supported. XML output is not.
  • The addressdetails, extratags, namedetails, countrycodes, viewbox, bounded, limit, accept-language and zoom parameters are honoured.

If your client depends on a field or behaviour that is not listed here, tell us. Compatibility gaps get fixed quickly because they are usually small.

Other drop-in hosts

How the drop-ins work, the overview, and the JavaScript library drop-ins.