The Design of Software (CLOSED)

A public forum for discussing the design of software, from the user interface to the code architecture. Now closed.

The "Design of Software" discussion group has been merged with the main Joel on Software discussion group.

The archives will remain online indefinitely.

looking for zip code lookup service

I'm looking for a web service that I can call with a street address, city and state and which will return a zip code.  Also, given a zip code, one which will return a city & state.

Anything like this out there, hopefully free or reasonably priced?  What about databases online or on CD-ROM that I could obtain?

I found a web service that does a bulk dump of zip code/city listings, and USPS sells a CD with a zip code viewer (but the data is encrypted).  But no going from street address to zip code.  Must be something out there...

NPR Send private email
Tuesday, December 19, 2006
I believe that the USPS publishes a free database for this purpose.  We've used it in the past but switched to MapInfo because we also had to do some geospatial stuff.  I think you  can download their data file from
Steve Send private email
Tuesday, December 19, 2006
It looks like the post office still has their zip+4 web service available, although hard to find:
Tuesday, December 19, 2006
Sweet.  That looks like it will do.
NPR Send private email
Tuesday, December 19, 2006
I used to do this long ago with Census DIME files. It looks like they've renamed them to TIGER, but they're still around, and freely downloadable.
Mark Ransom Send private email
Tuesday, December 19, 2006
You may want to chat with the developer of this site:

He does unbelievable geographic lookups.
Steve Hirsch Send private email
Tuesday, December 19, 2006
I didn't realize TIGER had zip codes.  I'll have to check into it.

When I get done with this part I'm going to add a lat/lon lookup and Google Maps integration.  This is for a hobby project, and I'm kind of excited about it.
NPR Send private email
Tuesday, December 19, 2006
Just FYI - The USPS WebTools links probably won't do you any good. They're supposed to be used for shipping, and not for address/zip code validation. The USPS won't give authorization just for validation purposes.

I have several apps that record client information, and we're always having problems with invalid zip codes. I tried to use the USPS data via their webtools, but (even though I'm with a state government) they wouldn't let me; they sent me the link to their purchasable subscription database.

KenW Send private email
Wednesday, December 20, 2006
You can only use the USPS Web Tools address and zip code validation service in the context of shipping a package through USPS Web Tools.
MBJ Send private email
Thursday, December 21, 2006
You can also use the Yahoo! Maps geocoding API.  It will give you both scenarios you are looking for:

 IN: zip
 OUT: city/state

 IN: address, city, state
 OUT: zip+4

Note, it's free, but according to their documentation, it's limited to 5000 calls per day per IP. 

Search on Yahoo for "geocoding api" or go to this link.

Google also probably has something similar, but I know the Yahoo one works from experience. 

Also, this may not matter to your project, but zip codes sometimes map to multiple towns/cities.  This can get some customers up in arms when they type in a zip code and your application tells them they live in a neighboring city, which may have a much worse reputation than their actual city.
Andy Scott Send private email
Thursday, January 04, 2007

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics
Powered by FogBugz