Coastal fortifications of New Zealand

Coastal fortifications were constructed in New Zealand in two main waves: around 1885 as a response to fears of an attack by Russia, and in World War II due to fears of invasion by the Japanese.
The fortifications were built from British designs adapted to New Zealand conditions. They typically included gun emplacements, pill boxes, fire control or observation posts, camouflage strategies, underground bunkers, sometimes with interconnected tunnels, containing magazines, supply and plotting rooms and protected engine rooms supplying power to the gun turrets and searchlights. There were also kitchens, barracks, and officer and NCO quarters.
The "Russian-scare" forts of 1885.
In the 1870s New Zealand was a young self-governing colony of Britain. It had developed no coastal defences of any consequence and was becoming increasingly sensitive to how vulnerable its harbours were to attack by a hostile power or opportunistic raider. In the aftermath of the Crimean war, Tsarist Russia seemed particularly suspicious. 
(In 1873 an Auckland editor perpetrated) ...what has been hailed the greatest spoof in the country's history. The Monday, 18 February 1873 edition of the "Southern Cross" reported the sudden declaration of war between England and Russia. As a result, the Russian warship "Kaskowiski" – whose very name should have made sober readers suspicious – had allegedly entered Auckland Harbour on the previous Saturday night and proceeded to capture a British ship, along with the city's arms and ammunition supply, and hold a number of leading citizens for ransom. The 954-man Russian vessel obviously meant business, with a dozen 30-ton guns as well as a remarkably new advance in warfare, a paralysing and deadly "water-gas" that could be injected into enemy ships from a great distance.
The "Southern Cross" article created panic and the Government commissioned its first reports on the colony's defences. It was now clearly understood that Britain would protect its territories and vital shipping routes, but the defence of individual ports was the responsibility of each self-governing colony. Then Russia declared war on Turkey in 1877 producing another "scare". The decision was taken to construct fortifications and purchase naval boats which would protect the harbours at Auckland, Wellington, Lyttelton and Port Chalmers. These coastal artillery fortifications or land batteries were to be based on British designs. Heavy artillery pieces and ammunition was ordered from Britain. By 1885 work started in earnest on the construction of what eventually became seventeen forts, further encouraged by yet another Russian scare.
Artillery.
In 1885 the New Zealand Government bought ten Armstrong BL 8-inch and thirteen Armstrong BL 6-inch guns on disappearing carriages. The disappearing gun was the very latest in military technology in the 1880s. It was "disappearing" because as it fired, the recoil pushed the gun back underground where it could be reloaded under cover. The total costs of this artillery plus the costs of installation including land, emplacements, magazines and barracks was about £160,000.
Following the "second Russian scare" a number of additional RML 7-inch and 64-pr guns were also installed 
World War II coastal fortifications.
The second main wave of building coastal fortifications occurred during World War II. This was mainly a response to a perceived threat of invasion by the Japanese after the attack on Pearl Harbor. From 1942 until 1944, when the threat receded, 42 coastal artillery fortifications or land batteries were either developed using historical fortifications or were built from scratch. The fortifications were built from British designs adapted to New Zealand conditions. Radar was installed which allowed long range shooting at night and replaced the traditional fortress system of range finding.
Ordnance.
The fortifications were equipped with both old and new ordnance, mostly British. Some World War I ordnance was requisitioned from museums and recommissioned.
The fortifications.
The fortifications were administered by the Royal New Zealand Artillery, which grouped them into four areas. Each area was under the command of a heavy artillery regiment. Within each regiment the fortifications were grouped into batteries.
Upper North Island.
Under the command of the 9th Heavy (Coast) Regiment.
Lower North Island.
Under the command of the 10th Heavy (Coast) Regiment.
Upper South Island.
Under the command of the 11th Heavy (Coast) Regiment.
Lower South Island.
Under the command of the 13th Heavy (Coast) Regiment.
Post war.
The advent of air warfare and missiles made these forts redundant and most were decommissioned by the 1950s. Godley Head continued because of compulsory military training and last fired a gun in 1959. The Department of Conservation has the remains of around 30 installations on land it manages.
Postscript.
None of the forts fired a gun in anger, though in October 1939 a Battery Point gun at Lyttleton accidentally sank the fishing boat "Dolphin" and killed its skipper.
In 1972 the United States declassified a contingency plan for invading New Zealand. This plan consisted of a 120-page intelligence document called "Naval War Plan for the Attack of Auckland, New Zealand". The intelligence for the report was gathered during the visit of the Great White Fleet to Auckland over six days in 1908. The plan advocated Manukau Harbour as the best invasion point and landing heavy guns on Rangitoto Island to shell the forts on the North Shore. The plan was not very realistic and may have been an exercise to keep young officers busy (see United States war plans; which allocated the colour Garnet to New Zealand as part of War Plan Red).