ZIP Code
ZIP Code vs ZIP+4
A ZIP Code is the postal code field used in U.S. addresses. Most forms accept a five-digit ZIP Code, while some billing, shipping, tax, and enterprise systems also accept ZIP+4.
What is a five-digit ZIP Code?
The five-digit format is the version most users recognize, such as 10001, 90015, or 60601. In test data, it is commonly used to check basic length validation, numeric input handling, city/state pairing, and CSV import fields.
What is ZIP+4?
ZIP+4 adds a hyphen and four extra digits after the standard ZIP Code, such as 10001-1234. The extra digits represent a more specific delivery segment. For product testing, ZIP+4 is useful because it catches forms that reject hyphens, trim values incorrectly, or store postal codes as numbers.
Format comparison for QA
| Format | Example | Test purpose |
|---|---|---|
| Five-digit ZIP Code | 02108 | Checks fixed-length text handling and leading zeros. |
| ZIP+4 | 02108-1234 | Checks hyphen validation and maximum length. |
| Blank value | Empty | Checks whether the field is optional for the selected country. |
| Wrong-country value | SW1A 1AA | Checks that country changes update the validation rule. |
Testing recommendations
- Test both 5-digit and ZIP+4 formats if your product handles billing or shipping addresses.
- Store ZIP Codes as text, not numbers, because leading zeros can appear in some states.
- Do not assume ZIP Code alone proves an address is real or deliverable.
- Include ZIP+4 values in CSV import tests to confirm the hyphen is preserved.
References
Generate ZIP Code samples
The U.S. address generator can create random examples with both standard ZIP Codes and occasional ZIP+4 values for QA and demo datasets.