Postcodes.io
by postcodes.io
Location Information
Added on October 31st, 2026
Checked and working on November 16th, 2026
Visit postcodes.io →
What it does
Postcodes.io is a free and open source API for UK postcodes, based on open data from the Office for National Statistics and Ordnance Survey. Look up and validate postcodes, get their coordinates and administrative areas (district, ward, constituency), find the nearest postcodes to a point, and autocomplete partial postcodes. Bulk lookups are supported. Responses are JSON and no key is needed.
At a glance
- API key
- Not needed · More APIs with no key
- From the browser
- Yes (CORS)
- Formats
- JSON
- Interface
- REST, HTTP-GET
- Provider
- postcodes.io
- Last checked
- Working on November 16th, 2026
More information: https://postcodes.io/
Is this your service? Show that it is listed
Put this badge on your website or in your README; it links to this page. About the badge
Example request
curl
curl 'https://api.postcodes.io/postcodes/SW1A1AA'
JavaScript
const response = await fetch("https://api.postcodes.io/postcodes/SW1A1AA");
const data = await response.json();
console.log(data);
Python
import requests
response = requests.get(
"https://api.postcodes.io/postcodes/SW1A1AA",
timeout=30,
)
print(response.json())
The JavaScript works in a web page as well as in Node.js 18 or newer.