4

I have most geocoded UK postcodes and would like to obtain all streets close to each postcodes. I am aware of this open data source:

https://www.ordnancesurvey.co.uk/business-and-government/products/os-open-roads.html

Which gives you most:

Motorways, A-roads, B-roads

Unfortunately, this is not as exhaustive as I thought. Is anyone aware of any other exhaustive/complementary data sources? Thanks.

3

1) getAddress.io

You can use this API which provides a free plan for limited calls (and paid for more) to check if it works for you. In specific, you call the API with the postcode as the parameter and it returns all the related addresses.

2) OpenStreetMap

I am not 100% sure about this, but if I remember well, they provide a free API where you can search from address to postcode and postcode to address. However, you may need to search for their documentation and how you can do this.

3) Info from Reddit

This is a copy paste from a user in Reddit who suggested something more.

You normally have to license this dataset from the Post Office for an extortionate fee. Wikileaks leaked the database in 2009, though I obviously wouldn't recommend using it for non-personal projects.

Not sure if it is allowed to post a link from Wikileaks. It would be great if a mod could clarify it.

  • Thanks getAddress.io looks really interesting. However, it does not explicitly tell you which filed the street name is. So would not help me with the above requirement ... – cs0815 Dec 5 '15 at 11:03
3

One option is to get a polygon dataset for postcodes (several of these free online), and a dataset for roads (open streetmap etc).

Loading both into a database with geo extensions like postgres you can use spatial SQL to ask "what postcode(s) is this road in".

  • Yeah thought about this. The problem is that 'street data sources' such as open streetmap are not complete. They only tend to contain data down to the A road level - i.e. the data is not fine grained/complete. – cs0815 Jan 3 '16 at 12:10
  • OSM should be very detailed - I link a 1GB map file that should contain every road in the UK down to small paths - you'll want to use ogr2ogr to push this into postgres and along with a postcodes shapefile and then get a list of roads for each postcode through sql download.gisgraphy.com/openstreetmap/pbf/GB.tar.bz2 – user4705201 Jan 4 '16 at 9:59
  • Thanks for that - I'll have a look. I have created a relational database a while back and was not impressed by its completeness. The db consists of 3 table: [MOTORWAYJUNCTION] (637 rows), [ROADLINK] (3181442 rows) and [ROADNODE] (2637720 rows). Maybe this is not the same database? – cs0815 Jan 4 '16 at 10:46
  • Don't know, and not able to check. Last time I worked with one of these files it seemed to have a lot of road data. – user4705201 Jan 4 '16 at 10:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.