Loading
Loading
The forward geocoding API converts any address, business name, or free-form place query into precise WGS84 latitude and longitude coordinates in a single GET request. Every result returns the matched coordinates together with a complete structured address — street, postcode, city, county, state with its standardized subdivision code, and country — plus point-of-interest details and the spatial extent of the match. It is built for developers adding address validation to checkout flows, powering store locators, and geocoding datasets for logistics and mapping platforms — a straightforward Google Maps Geocoding API alternative with plain JSON output and no SDK dependency.
The query parameter accepts full postal addresses, partial addresses, business names, and landmark references with no preprocessing or strict formatting on your end. The API resolves the input and returns the best matches it finds.
Use it for geocoding messy, user-typed address data straight from forms without building a normalization layer first.
The limit parameter controls how many matches come back, from 1 to 40, with a default of 1. Each result is a complete, independently usable match with its own coordinates and address breakdown.
Use limit=1 for single-match address validation, and higher values for search interfaces where the user picks from candidate locations.
Pass min_lat, max_lat, min_lon, and max_lon together to define a rectangular search area, and results are restricted to that region only. Requests missing any of the four parameters return a 400.
Use it when your application is scoped to one city, zone, or delivery area and out-of-region matches are noise.
When a query resolves on or near a known amenity, building, or landmark, the poi array returns the name, category, and type of that place alongside the standard address fields.
Use it to label results with recognizable place names instead of bare street addresses in search and map interfaces.
Every result includes individual fields for street, neighbourhood, postcode, city, county, state, and country, and the state_code field follows the ISO 3166-2 standard. A full_address string delivers everything as one pre-formatted line.
Use the individual fields for structured storage and filtering, or full_address when you just need display text.
Pass an Accept-Language header with a single code or a comma-separated preference list to receive address data in that language. The API falls back to English when the requested language is unavailable for a location.
Use it to localize address display in multi-region products without post-processing the response.
Returned lat and lon values use the WGS84 decimal degree standard, compatible with virtually every mapping library, GIS platform, and spatial database. Each result also includes a bounding_box array with the spatial extent of the matched feature as [lat_min, lat_max, lon_min, lon_max].
Use the coordinates to place markers and the bounding box to set the initial map zoom for each match.
Geocode the address a customer types at checkout and request only the single best match. A successful match with a complete structured address confirms the location is real before it reaches your fulfillment or billing systems; a no-match response flags the entry for correction at the point of entry.
Restrict geocoding to a rectangular area covering your service region so a search for a branch, partner location, or generic place name never returns matches from the wrong city. Combine a wider result limit with the region restriction to present a pick-list of nearby candidates.
Run customer files, delivery manifests, or property records through the API to attach coordinates to every row, then plot them, cluster them, or feed them into routing. For records that arrive as coordinates instead of addresses, the Reverse Geocoding API handles the inverse conversion in the same response shape.
Geocode a pickup or service address, then resolve the local time at the returned coordinates with the Timezone Lookup API to schedule deliveries, technician visits, or notifications in the customer's own timezone.
$ pip install requestsimport requests
url = "https://api.apifreaks.com/v1.0/geocoder/search?query=1600+Amphitheatre+Parkway%2C+Mountain+View%2C+CA&limit=1"
payload = {}
headers = {
'X-apiKey': 'API-KEY'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text)
Set limit=1 when you only need the top match for a specific address.
# Response [ { "lat": 37.42248575, "lon": -122.08558456613565, "name": "Google Building 41", "category": "building", "type": "commercial", "poi": [ { "name": "Google Building 41", "category": "building", "type": "commercial" }, { "name": "1600", "category": "place", "type": "house_number" } ], "street": "Amphitheatre Parkway", "postcode": "94043", "city": "Mountain View", "county": "Santa Clara County", "state_code": "US-CA", "state": "California", "country_code": "US", "country": "United States", "full_address": "Google Building 41, 1600, Amphitheatre Parkway, Mountain View, Santa Clara County, California, 94043, United States", "bounding_box": [ "37.4221124", "37.4228508", "-122.0859868", "-122.0851511" ] } ]curl "https://api.apifreaks.com/v1.0/geocoder/search?apiKey=YOUR_API_KEY&query=1600%20Amphitheatre%20Parkway%2C%20Mountain%20View%2C%20CA&limit=1"
When you need local time data for returned latitude and longitude values, use the timezone from coordinates endpoint.
When the query is a business name or landmark, set limit higher to return several candidate matches.
# Response [ { "lat": 40.757009499999995, "lon": -73.98597239146777, "name": "Times Square", "category": "highway", "type": "pedestrian", "street": "Times Square", "area": "Manhattan, New York County", "postcode": "10036", "city": "New York", "state_code": "US-NY", "state": "New York", "country_code": "US", "country": "United States", "full_address": "Times Square, Theater District, Manhattan Community Board 5, Manhattan, New York County, New York, 10036, United States", "bounding_box": [ "40.7558313", "40.7591362", "-73.9870666", "-73.9845108" ] }, { "lat": 40.757261400000004, "lon": -73.98589982948505, "name": "Times Square", "category": "tourism", "type": "attraction", "area": "Manhattan, New York County", "postcode": "10036", "city": "New York", "state_code": "US-NY", "state": "New York", "country_code": "US", "country": "United States", "full_address": "Times Square, 7th Avenue, Theater District, Manhattan Community Board 5, Manhattan, New York County, New York, 10036, United States", "bounding_box": [ "40.7564751", "40.7580455", "-73.9866378", "-73.9853729" ] }, { "lat": 40.7555923, "lon": -73.9858388, "name": "Times Square", "category": "railway", "type": "station", "poi": [ { "name": "Times Square", "category": "railway", "type": "station" } ], "street": "West 42nd Street", "area": "Manhattan, New York County", "postcode": "10036", "city": "New York", "state_code": "US-NY", "state": "New York", "country_code": "US", "country": "United States", "full_address": "Times Square, West 42nd Street, Midtown, Manhattan Community Board 5, Manhattan, New York County, New York, 10036, United States", "bounding_box": [ "40.7505923", "40.7605923", "-73.9908388", "-73.9808388" ] }, { "lat": 40.75847625, "lon": -73.98529451938359, "name": "Times Square", "category": "tourism", "type": "artwork", "poi": [ { "name": "Times Square", "category": "tourism", "type": "artwork" } ], "street": "Times Square", "area": "Manhattan, New York County", "postcode": "10036", "city": "New York", "state_code": "US-NY", "state": "New York", "country_code": "US", "country": "United States", "full_address": "Times Square, Theater District, Manhattan Community Board 5, Manhattan, New York County, New York, 10036, United States", "bounding_box": [ "40.7584086", "40.7585614", "-73.9853379", "-73.9852297" ] }, { "lat": 40.756983950000006, "lon": -73.98626560946721, "name": "Times Square", "category": "landuse", "type": "commercial", "area": "Manhattan, New York County", "city": "New York", "state_code": "US-NY", "state": "New York", "country_code": "US", "country": "United States", "full_address": "Times Square, Manhattan, New York County, New York, United States", "bounding_box": [ "40.7536202", "40.7622040", "-73.9906088", "-73.9819367" ] } ]curl "https://api.apifreaks.com/v1.0/geocoder/search?apiKey=YOUR_API_KEY&query=Times%20Square%20New%20York&limit=5"
Add the four viewbox parameters to filter results to a defined geographic area. All four must be included together.
# Response [ { "lat": 40.75569, "lon": -73.9418423, "name": "Coffee Shop", "category": "amenity", "type": "restaurant", "poi": [ { "name": "Coffee Shop", "category": "amenity", "type": "restaurant" }, { "name": "13-01", "category": "place", "type": "house_number" } ], "street": "40th Avenue", "area": "Queens, Queens County", "postcode": "11101", "city": "New York", "state_code": "US-NY", "state": "New York", "country_code": "US", "country": "United States", "full_address": "Coffee Shop, 13-01, 40th Avenue, Queensbridge, Queens, Queens County, New York, 11101, United States", "bounding_box": [ "40.7556400", "40.7557400", "-73.9418923", "-73.9417923" ] } ]curl "https://api.apifreaks.com/v1.0/geocoder/search?apiKey=YOUR_API_KEY&query=coffee%20shop&limit=5&min_lat=40.4774&max_lat=40.9176&min_lon=-74.2591&max_lon=-73.7004"
limit value when building region-scoped search features.A query with no matching location returns a 404, and invalid parameters return a 400 with a specific reason. No credits are charged on either — only 2xx responses are billed. Treat a 404 as a data-quality signal, not a retry case: the address needs correction before resubmitting.
# Response HTTP/2 404 { "timestamp":"2026-06-12T09:19:11.146Z", "path":"/v1.0/geocoder/search", "status":404, "error":"No Result Found", "message":"No results found for the given query." }curl -i "https://api.apifreaks.com/v1.0/geocoder/search?apiKey=YOUR_API_KEY&query=asdfqwerty123nonexistent&limit=1"
lat and lon in WGS84 decimal degrees, a structured address (street, postcode, city, county, state with state_code, country with country_code), a single-line full_address, a bounding_box array, and a poi array with name, category, and type when the match falls on a known place.query parameter is free-form text: full postal addresses, partial addresses, business names, and landmarks all work. No preformatting or structured input is required.lat / lon pair into the nearest structured address. Use forward when you start from an address, reverse when you start from GPS coordinates.min_lat, max_lat, min_lon, max_lon — to limit matches to a rectangular area. Omitting any of the four returns a 400, and queries with no matches inside the box return a 404.Accept-Language header with a language code or a comma-separated preference list. When the requested language is not available for a location, the response falls back to English.To use the Forward Geocoding API, you will need API credits. We only charge for successful queries, defined by a 2xx status code. If your request results in a 4xx or 5xx status code, no credits will be charged, and any deducted credits will be returned.
For Each Successful request 10 credits will be charged.
Utilize the Credits Usage API to efficiently monitor your recent consumption of both one-off and subscription credits. This API provides a streamlined way to track and manage your credit usage, ensuring you stay informed about your remaining balance and can optimize your resource allocation effectively.