Skip to content

Postcodes.io API: List nearby postcodes

Lists UK postcodes nearest to a postcode or named place, with distance, ward, council and coordinates. For places sharing a name, a city or town is preferred.

postcodes.io (opens in a new tab)Version 1ReadNo sign-inVerified Nov 2, 2026

Unofficial. Not affiliated with or endorsed by Postcodes.io.

Inputs

Values from the run on Oct 23, 2026, shown under Output.

Near, requirednear

A UK postcode or place name, for example SW1A 1AA or Oxford.

SW1A 1AA

Max Results optionalmax_results

Maximum number of nearest postcodes, for example 10.

10 (default)

Whole number from 1 to 100.

Radius (metres) optionalradius_metres

Maximum distance in metres from the postcode or place, for example 1000.

1000 (default)

Whole number from 1 to 2000.

Output

From a run on Oct 23, 2026, shortened for this page.
{  "postcodes": [    {      "ward": "St James's",      "latitude": 51.50101,      "page_url": "https://postcodes.io/postcodes/SW1A%201AA",      "postcode": "SW1A 1AA",      "longitude": -0.141563,      "local_council": "Westminster",      "distance_metres": 0    },    {      "ward": "St James's",      "latitude": 51.499933,      "page_url": "https://postcodes.io/postcodes/SW1E%206LA",      "postcode": "SW1E 6LA",      "longitude": -0.141117,      "local_council": "Westminster",      "distance_metres": 123.67233656624896    },    {      "ward": "St James's",      "latitude": 51.499738,      "page_url": "https://postcodes.io/postcodes/SW1E%206AY",      "postcode": "SW1E 6AY",      "longitude": -0.140736,      "local_council": "Westminster",      "distance_metres": 152.5853742672548    }  ]}
Price
1 credit per completed run (1¢ with pay as you go); failed runs are free.
Method
postcodes.io/list_nearby_postcodes
Returns
postcode, distance, ward, council, latitude, longitude, page URL

Use it from your agent

Give your agent this line. It reads SKILL.md, gets a Fous API key and connects the Fous MCP server. Its run then takes the method postcodes.io/list_nearby_postcodes with the inputs above.

Ask your agent

  • What postcodes are within 500 metres of SW1A 1AA, and which councils do they belong to?
  • Give me the 15 closest UK postcodes to Oxford with their wards and coordinates.
  • Find nearby postcodes around Leeds city centre within a 1500 metre radius, including distances.
  • I need the nearest postcodes to M1 1AE on postcodes.io, up to 20 results, with latitude and longitude.
  • List the postcodes within 800 metres of Bristol Temple Meads showing ward and council names.
  • Looks up a UK postcode on Postcodes.io, including its location, administrative areas and whether it is still in use. Retired postcodes return location and retirement year only.

    postcodes.io/get_postcode
  • Gets crimes reported within one mile of a UK postcode or place in England, Wales or Northern Ireland for a month (latest published by default), with category totals, up to 100 sampled incidents, the previous month's total and the local police.uk crime-map link.

    data.police.uk/get_crimes_near_postcode
  • Finds the neighbourhood policing team for a UK postcode (England, Wales, Northern Ireland) with its force, contacts, officers, priorities and upcoming events.

    police.uk/get_neighbourhood_team
  • Find nearby NHS service listings from a UK postcode or town, nearest first. NHS service search covers England; urgent_care returns A&E listings. Hours, patient availability and websites are null when not shown.

    nhs.uk/search_nearby_services
  • Finds Open Charge Map charging locations near an address, city, or postcode, nearest first.

    openchargemap.org/search_chargers
  • Finds Indian post offices matching a place name, with PIN codes, branch types, delivery statuses, districts and states. Optionally narrows by state or district.

    postalpincode.in/search_pin_codes
  • Finds Starbucks cafés near a city, address or ZIP code, nearest first, with whether each is open now, today's local hours and amenities; optionally only cafés open now.

    starbucks.com/search_stores
  • Finds GreatSchools schools within 5 miles of a US address, city or ZIP code. Results can be filtered by grade and school type and sorted by distance or rating.

    greatschools.org/search_schools