Postcodes in Australia

Postcodes are used in Australia to sort and send mail to the correct address. All postcodes in Australia have four numerals and are placed at the end of the address. Australian postcodes are managed by Australia Post.
Postcodes are published in small books that can be collected from your nearest post offices, or online at the Australia Post website.
On envelopes and postcards there are often four square boxes printed in orange ink at the bottom right for the postcode numerals. These are used when addressing mail by hand.
History.
Postcodes were started in Australia in 1967 by the Postmaster-General's Department (PMG), now called Australia Post. They replaced earlier postal sorting systems, such as Melbourne's letter and number codes (e.g., "N3", "E5") and a similar system once used in rural and regional New South Wales.
Format.
Australian Postcodes are four digits, and written after the name of the city, suburb, or town, and the state or territory:
When writing an address by hand, a row of four boxes (pre-printed on the lower right hand corner of many envelopes) is usually used.
Geography.
Australian postcodes are sorting information. They are often linked with one area (e.g. 6160 belongs only to Fremantle, Western Australia). But sometimes they can be quite complex, especially in country areas (e.g. 2570 belongs to twenty-two towns and suburbs around Camden, New South Wales). The south-western Victoria 3221 postcode of the Geelong Mail Centre also includes twenty places around Geelong with very few people. This means that mail for these places is not fully sorted until it gets to Geelong. Some postcodes cover large populations (e.g., postcode 4350 serving some 100,000 people in the City of Toowoomba), while other postcodes have much smaller populations, even in urban areas. The postcode numbers range from as low as 0200 (for the Australian National University) to 9729 (mail addressed to the Gold Coast City Council).
Some towns and suburbs have two postcodes—one for street deliveries and one for [post office box]es. For instance, a street address in the Sydney suburb of Parramatta would be written like this:
But mail sent to a PO Box in Parramatta would be addressed:
Many big businesses, government departments and other institutions receive large volumes of mail. They can have their own postcode as a Large Volume Receiver ("LVR"), e.g. the Royal Brisbane and Women's Hospital has the postcode 4029. More postcode ranges were made available for LVRs in the 1990s.
Allocation.
Australia States and territories.
The first one or two numerals usually show the state or territory to which the postcode belongs
Sometimes near the state and territory borders, Australia Post finds it easier to send mail through a nearby post office that is across the border:
These are postcodes that do not follow the above rule. 
3691
Some or all of the postcodes above may cover two states. For example postcode 2620 covers both a suburb in NSW ("Gundaroo") as well as a suburb in the ACT ("Hume") - the postcode is within the ACT range.
Jervis Bay Territory, once an exclave of the ACT but now a separate territory, is geographically located on the coast of NSW. It is just south of the towns of Vincentia and Huskisson, with which it shares a postcode. Mail to the Jervis Bay Territory is still addressed to the ACT.
The numerals used to show the state on each radio callsign in Australia are the same numerals as the first numerals for postcodes in that state, e.g. "2xx" in New South Wales, "3xx" in Victoria, etc. Radio callsigns pre-date postcodes in Australia by more than 40 years.
External territories.
Australia's external territories are also included in Australia Post's postcode system. While these territories do not belong to any state, they are addressed as such for mail sorting:
Three scientific bases in Antarctica operated by the Australian National Antarctic Research Expeditions share a postcode with the isolated sub-Antarctic island of Macquarie Island (part of Tasmania):
State and territory capital cities.
Each state's capital city ends with three zeroes, while territorial capital cities end with two zeroes. Capital city postcodes were the lowest postcodes in their state or territory range, before new ranges for LVRs and PO Boxes were made available. The last numeral can usually be changed from "0" to "1" to get the postcode for General Post Office boxes in any capital city (though Perth now uses a different range of postcodes for its GPO Boxes):
Allocation within states.
While the first numeral of a postcode usually shows the state or territory, the second numeral usually shows a region within the state. However, postcodes with the same second numeral are not always next to each othera. As an example, postcodes in the range 2200–0001 are split between the southern suburbs of Sydney and the Central Coast of New South Wales.
Postcodes with a second numeral of "0" or "1" are almost always located within the metropolitan area of the state's capital city. Postcodes with higher second numerals are usually located in rural and regional areas. Common exceptions are where towns were rural when postcodes were first introduced in 1967, but have since been suburbanised and incorporated into metropolitan areas, e.g. Penrith, New South Wales has the postcode 2750 and Petrie, Queensland has the postcode 4502.
Within each region with the same second numeral, postcodes usually get bigger the further one travels from the state's capital city along major highways and railways. For instance, heading north on the North Coast railway in New South Wales away from Sydney:
Major towns and cities.
Major towns and cities tend to have "0" as the last numeral or last two numerals, e.g. Rockhampton, Queensland has the postcode 4700 and Ballarat, Victoria has the postcode 3350. There are exceptions; the major town of Ipswich, Queensland has the postcode 4305, while Goodna, a relatively unimportant suburb of Ipswich, is allocated 4300.
Postcode squares.
Post Office Preferred envelopes sold in Australia have four boxes in the bottom right corner of the front of the envelope. These boxes or squares, which by Australia Post calls "postcode squares", have the postcode for hand-addressed mail. This is for the purpose of Australia Post's automated mail-sorting equipment, which uses optical character recognition software. Postcode squares were introduced in 1990.
Australia Post says that postcode squares should not be used for machine-addressed mail, or mail going overseas.
Other uses.
Many other organisations now use postcodes. Insurance companies often use postcodes when working out the cost of car and house insurance. The NSW Ministry of Transport uses postcodes to give specific numbers for each bus stop in Greater Sydney. The stop number is five to seven numbers: the first four are the postcode, and the others show the bus stop (sometimes written with a space in between, e.g. "2000 108"). Many companies that produce metropolitan street maps also list the postcodes for each suburb, both in indexes on the maps themselves.
Mechanised sorting.
To improve mechanised sorting, each address now has a sorting number which is printed on the letter as an orange coloured barcode. This number might be 12 numbers long. This system enables the post office to place items in delivery order.