Loading
Loading
Look up location data for any ZIP or postal code worldwide. Returns city, region, country, coordinates, and locality for the given code. Optionally limit search to a specific country using an ISO 3166-1 alpha-2 country code.
Supports global postal systems including USPS, Royal Mail PAF, Canada Post, India Post, Japan Post, and more. Pass format=xml to receive an XML response instead of JSON.
Authorize every request with your API key, passed either as a header or as a query parameter:
X-apiKeyapiKeyThis is version v1.0 of the API.
The code parameter is required. The country parameter is optional but recommended to narrow results to a specific country.
formatoptionalStringdefault: jsonResponse format: 'json' (default) or 'xml'.
coderequiredStringdefault: ZIP or postal code to look up. Only one code per request.
countryoptionalStringLimits search to a specific country. Must be in ISO 3166-1 alpha-2 format (e.g., US, GB). If not provided, searches all countries.
A successful request returns a 200 OK with a JSON object containing a results array. Each element represents a matched postal code location.
code (String), country_code (String), region (String), region_code (String), city (String), …
Besides the response body, every response carries custom headers you can use to track credit usage, and concurrency usage on endpoints that enforce a concurrency limit. See the Custom Response Headers documentation and the endpoints with concurrency limits for more details.
X-Concurrent-Threadsheaderconcurrency-limited endpointsSpecifies the maximum number of concurrent requests allowed.
X-Concurrent-Threads-Activeheaderconcurrency-limited endpointsIndicates the number of active concurrent requests being processed.
X-AF-Credits-Costheaderall responsesSpecifies the number of credits consumed by the current request.
See the HTTP Status Codes documentation for a complete reference of common API errors and HTTP status codes.
Only ISO 3166-1 alpha-2 codes country codes are supported.
Provided postal/zip code was not found in our database.