Australian postcodes are always exactly 4 digits and follow a tight geographic allocation administered by Australia Post and documented in the ABS Postal Area (POA) geography. This validator checks any 4-digit code against the official range tables, identifies the state or territory it belongs to, distinguishes street-delivery ranges from non-geographic PO Box ranges, and flags the ACT/NSW and NT dual-block overlaps that trip up many address-handling systems. Everything runs locally — nothing is ever uploaded.
How it works
The validator first strips any whitespace and rejects non-numeric input. Australian postcodes are always exactly 4 digits, so any input shorter or longer is immediately flagged. It then compares the numeric value against a set of official range entries derived from the Australia Post Addressing Standards and the ABS Postal Area correspondence tables.
The leading digit of an Australian postcode is not a simple 1-to-1 map of one digit to one state. Several ranges overlap or are shared:
- 0xxx covers both the Northern Territory (0800-0999) and the Australian Capital Territory (0200-0299). Darwin CBD is 0800; Canberra City is 2601 (from the 2xxx block, not the 0xxx block).
- 2xxx is primarily New South Wales, but a band of postcodes from 2600-2618 and 2900-2920 was assigned to ACT suburbs (Canberra, Tuggeranong, Woden and surrounds) because the ACT sits physically inside the NSW boundary.
- 1xxx is entirely NSW non-geographic — PO Boxes, Locked Bags and Mail Houses. No streets have a 1xxx postcode.
- 8xxx is NT non-geographic (PO Boxes). The NT has two separate postcode blocks: street delivery in 0800-0999 and non-geographic in 8000-8999.
- Postcodes beginning with 9 are entirely unallocated in Australia.
For each valid range the validator returns the state abbreviation, the full state/territory name, the delivery type (street or non-geographic), and any overlap note. A small set of well-known CBD postcodes (Sydney 2000, Melbourne 3000, Brisbane 4000, Adelaide 5000, Perth 6000, Hobart 7000, Canberra 2600, Darwin 0800) is annotated where relevant.
Worked example
Suppose you receive the postcode 2600 from a web form alongside a delivery address in Canberra.
- The input is 4 digits — length check passes.
- Numeric value is 2600 — falls in the range 2600-2618.
- That range is assigned to ACT (Australian Capital Territory) as a street-delivery postcode (ACT overlap within the NSW 26xx block).
- Result: Valid — ACT, street delivery.
Now try 1234:
- Four digits — length check passes.
- Value 1234 falls in the 1000-1999 range.
- That range is NSW non-geographic (PO Boxes / Locked Bags / Mail Houses).
- Result: Valid structurally, but non-street — 1234 is a valid PO Box range postcode, not a street delivery address.
And try 9000:
- Four digits — length check passes.
- Value 9000 matches no allocated range.
- Result: Invalid — unallocated. No Australian postcodes start with 9.
| Postcode | State / Territory | Delivery type | Well-known suburb |
|---|---|---|---|
| 2000 | NSW | Street delivery | Sydney CBD |
| 3000 | VIC | Street delivery | Melbourne CBD |
| 4000 | QLD | Street delivery | Brisbane CBD |
| 5000 | SA | Street delivery | Adelaide CBD |
| 6000 | WA | Street delivery | Perth CBD |
| 7000 | TAS | Street delivery | Hobart CBD |
| 2600 | ACT | Street delivery | Canberra City |
| 0800 | NT | Street delivery | Darwin CBD |
| 1234 | NSW | PO Box / LVR | Non-geographic |
| 9000 | — | — | Unallocated |
Every check runs in your browser — no postcode you enter is sent to any server.