Finding City and Zip Code for a Location


Given a latitude and longitude, what is the easiest way to find the name of the city and the US zip code of that location.

(This is similar to, except I want to convert in the opposite direction.)

Related question: Get street address at lat/long pair

Best Solution

Any of the online services mentioned and their competitors offer "reverse geocoding" which does what you ask--convert lon/lat coordinates into a street address of some-sort.

If you only need the zip codes and/or cities, then I would obtain the Zip Code database and urban area database from the US Census Bureau which is FREE (paid for by your tax dollars).

From there, you can either come up with your own search algorithm for the spatial data or make use of one of a spatial databases such as Microsoft SQL Server, PostGIS, Oracle Spatial, ArcSDE, etc.

Update: The 2010 Census data can be found at: