The idea of a main trunk railway between Auckland and Wellington had been talked about since the 1860s, but during the Vogel era of the 1870s rail-building efforts were focused elsewhere in the colony. By 1880, Auckland's southern line reached as far as Te Awamutu, and isolated sections had been built in Taranaki, Manawatu, Hawke's Bay, and between Wellington and Wairarapa. Between southern Waikato and Manawatu lay thousands of hectares of rugged country, volcanic mountains, deep ravines, dense forests and Maori land.
The main trunk's large, cosmopolitan labour force lived and worked in harsh conditions, especially during the long King Country winters. Their isolated shantytowns offered few comforts – and few diversions other than gambling and drinking. According to Herman Foston's account, At the front, 'On a Saturday night, following pay-day, drunkenness was at times appalling, and free fights were quite common.'
Despite these obstacles, surveys of possible routes began in 1882. In 1884 a parliamentary committee opted for a central route over alternatives looping through Taranaki or Hawke's Bay. The government also reached a vital agreement with Ngati Maniapoto leaders to open up Te Rohe Potae (the King Country) – then off-limits to Europeans – to rail development.
On 15 April 1885 Premier Robert Stout, Wahanui Huatare and Rewi Maniapoto ceremonially turned the ‘first sod' of the central section at Puniu, near Te Awamutu. Despite high hopes, it would take another 23 years of exploration and surveying, parliamentary enquiries, and sheer hard work to complete the main trunk.
Engineering challenges were overcome in dramatic fashion. To accomplish the steep climb up to the Waimarino plateau, south of Taumarunui, R.W. Holmes designed the Raurimu Spiral, with its two tunnels, three horseshoe curves and complete circle. Massive steel viaducts, partly manufactured on site, bridged deep ravines at Makatote, Hapuawhenua, Mangaweka, Makohine and elsewhere.
By 1904 the northern and southern sections had reached Taumarunui and Taihape. Two years later the main trunk's workforce topped 2700, and in 1907 an extra shift was added, with workers toiling through the night under the glow of kerosene lamps.
By May 1908 the job was almost done. Only a 24-km gap remained, between the unfinished Makatote viaduct and Ohakune. The Public Works Department rushed to complete a temporary link-up by August, just in time to carry MPs north to greet the US Navy's Great White Fleet in Auckland.