Nominatim API

⭐ Beginner's Pick Geocoding / No Auth Required Beginner HTTPS CORS
Free to Use Varies (check documentation)

Overview

Nominatim is a free geocoding API powered by OpenStreetMap data that lets you convert addresses to coordinates (forward geocoding) and coordinates back to addresses (reverse geocoding). It covers the entire world and requires no API key for low-volume use. It is a great choice for open-source projects that need location lookup without licensing costs.

💡

Beginner Tip

Always set a custom User-Agent header with your app name and contact email — Nominatim requires it and will block requests without one. Limit your requests to 1 per second to comply with the usage policy.

Available Data

IP address details
latitude and longitude
city and country
timezone
ISP information

Example Response

JSON Response
{
  "status": "success",
  "data": {
    "result": "Data from Nominatim",
    "description": "Provides worldwide forward / reverse geocoding",
    "timestamp": "2025-01-15T10:00:00Z"
  }
}

Field Reference

[].place_id Internal Nominatim identifier for the place
[].display_name Full formatted address string for the result
[].lat Latitude of the location as a string
[].lon Longitude of the location as a string
[].type OSM element type (e.g., attraction, city, country)
[].importance Relevance score from 0 to 1; higher means more prominent result

Implementation Example

const url = "https://nominatim.org/release-docs/latest/api/Overview/";
const response = await fetch(url);
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data);

What Can You Build?

Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.

Common Errors & Troubleshooting

429 Too Many Requests You are sending more than 1 request per second
Add a delay of at least 1 second between requests; for bulk geocoding, use a local Nominatim instance instead
Empty results array The address could not be found or is too ambiguous
Add country or city context to the query (e.g., "Berlin, Germany") and avoid abbreviations
Blocked requests Missing or generic User-Agent header
Set the User-Agent header to something identifying your application, like "MyProjectName [email protected]"

Matrix Score Breakdown

🌐 Reachability 30/30
⚡ Speed 15/20
🔒 Security 15/15
🛠 Developer XP 20/20
✓ Reliability 7/15
Response Time 314ms

Fully tested on Apr 5, 2026

Technical Specifications

Auth No Auth
HTTPS REQUIRED
CORS YES
Category Geocoding
Difficulty Beginner
Verified: 2026-04-04

Alternatives to Nominatim

Technical alternatives for different use cases.

Free OpenStreetMap-based geocoding, self-hostable

Better For

Structured US address parsing and verification

Trade-off

Self-hosted geocoding without API limits

Similar APIs

View All →