Plenty Of Zip Codes For Form Auto-Completion
zippopotam.us
zippopotam.us
Love,
People-in-Ireland-tired-of-typing-fake-postal-codes
I've always wanted to use such a library for my checkout forms and whatnot, but unfortunately it doesn't fit the typical UI paradigm.
If you need the address info, you'll (almost) never ask for the zip code before the city and state, so the information has already been filled in before the user gets that far... and the country comes last.
Users are used to entering the address info in that natural order: street, city, state, zip, country (usually pre-set to your biggest userbase). I think the cognitive overhead of mixing that order up actually exceeds the effort of having them fill in all 3 fields.
The only place I could see you using something like this is if your are tailoring your services to a US-only userbase (so you can guarantee that a zip code is there and that the other info will not need to be manually entered). For example, we use ziptastic (at the server side for cross-domain reasons) at http://gastomorrow.com/ which is a US-only service to guess the price of gas tomorrow in your area.
The databases aren't always as complete as the developers believe them to be though -- sensible operators will leave a way to override the lookup, others lose out on custom from people living in new estates.
Also, to the author(s) of zippopotam.us, if they're reading: - How can we trust you're not going away any time soon? I don't see any pricing, so I assume this is all free? - Related to the first point, I assume you don't want to be used by any high traffic site, since you probably don't have a lot of server power behind this. What's the plan?
Address lookup or just validation?
For validation, there's an official regex (archived, but still useful) http://www.cabinetoffice.gov.uk/govtalk/schemasstandards/e-g....
For address lookup there are a couple of ways to go about it.
1. You can buy the rights to the Royal Mail's database. You get to parse the sucker yourself. http://www.poweredbypaf.com/end-user/products/paf-raw-data/
2. You can use a third party system, either over the web, or choose a solution you can host internally. Depending on the type of system you buy you pay by the lookup or by the user (mostly internally hosted systems).
[1] http://www.ordnancesurvey.co.uk/oswebsite/products/code-poin...
We are hosted on DotCloud(YCS10) - and thanks to generous agreement with them, we have a very large free plan and until we have issues managing demand, we don't plan to ask for donations.
Several well known sites us zippopotam.us such as TheNounProject and Pocket.
There are several alternatives to us and if don't trust us, don't use us - our intention is to serve sites that can't be bothered to download dbs and serve the codes themselves.
For example: https://tools.usps.com/go/ZipLookupResultsAction!input.actio...
http://www.census.gov/geo/www/tiger/zip1999.html
However, please note that some information may be outdated. The US Postal Service now maintains the zip code data sources, but I'm not sure if you must pay for it.
Zippopotam.us only seems to deal with the first part, which is only of marginal utility.
Any reason there isn't JSONP support?