Reverse Geocoding API

Reverse Geocoding is a process to give the closest matching address to a provided geographical coordinates (latitude/longitude). MapmyIndia reverse geocoding API provides real addresses along with nearest popular landmarks for any such geo-positions on the map.

  1. Basic URL structure:<licence_key>/rev_geocode?lat=<latidude>&lng=<longitude>
  2. Output: The output format would be JSON.
  3. HTTP Request Method: GET
Request Parameters

The following input parameters will be supported in the Reverse Geocoding API request –

  1. lat: the latitude of the location for which the address is required.
  2. lng: the longitude of the location for which address is required.
  3. licence_key: the REST API licence key allocated to you by signing into our services and registering yourself as a developer (28 Char Alphanumeric).
  4. region (string): it takes in the country code. LKA, IND, BTN, BGD, NPL for Sri-Lanka, India, Bhutan, Bangladesh, Nepal respectively. Default is India (IND)
Response Parameters

The API returns an enveloped response of reverse geocoded data in the results object which will be a collection containing a single Item. The following output parameters will be supported in the Reverse Geocoding API response –

  1. responseCode (int): The response code of the operation. The 400 series is for client side (yours) error while 500 series for server side (ours) error, 200 for success.
  2. version (string): The version of the API you’re connected to.
  3. results: array of single result, consisting of the following parameters
    • houseNumber (string): The house number of the location.
    • houseName (string): The name of the location.
    • poi (string): The name of the POI if the location is a place of interest (POI).
    • poi_dist (string): distance from nearest POI in metres.
    • street (string): The name of the street of the location.
    • street_dist (string): distance from nearest Street in metres.
    • subSubLocality (string): The name of the sub-sub-locality where the location exists.
    • subLocality (string): The name of the sub-locality where the location exists.
    • locality (string): The name of the locality where the location exists.
    • village (string): The name of the village if the location exists in a village.
    • district (string): The name of the district in which the location exists.
    • subDistrict (string): The name of the sub-district in which the location exists.
    • city (string): The name of the city in which the location exists.
    • state (string): The name of the state in which the location exists.
    • pincode (string): The pin code of the location area.
    • lat (double): The latitude of the location.
    • lng (double): The longitude of the location.
    • formatted_address (string): The complete human readable address string that is usually the complete postal address of the result.
    • area (string):in-case the co-ordinate lies in a country the name of the country would be returned or if the co-ordinate lies in an ocean, the name of the ocean will be returned.

The Geocode API must respond within 100 Ms under all circumstances on a stable internet connection although on an unstable one, response times may vary.

Transaction Information

One request using the API link will be considered as one transaction.

Use Cases
  • Get the address details of a latitude and longitude belonging to a location.



{  "responseCode": 200,  "version": "130.11",  "results": [  {  "houseNumber": "",  "houseName": "",  "poi": "",  "poi_dist": "",  "street": "",  "street_dist": "",  "subSubLocality": "",  "subLocality": "",  "locality": "",  "village": "Basopatti",  "district": "Madhubani District",  "subDistrict": "Basopatti",  "city": "",  "state": "Bihar",  "pincode": "847225",  "lat": "26.5645",  "lng": "85.9914",  "area": "India",  "formatted_address": "Sisauni, Harlakhi, Madhubani District, Bihar. 936 m from Primary Health Centre Basopatti pin-847225 (India)"  }  ]  }