His family emigrated to New Zealand in 1858 when he was four and Mackenzie was educated at Green Island School and at the Stone School, both in Dunedin.
He tried his hand at surveying, farming and commerce. Mackenzie was elected to the New Zealand Parliament for Clutha in 1887. He resigned in 1896 to assess the British markets for New Zealand products and remained in his native land for three years.
On his return to New Zealand he was elected to Parliament successively for Waihemo 1900–1902, Waikouaiti 1902–1908, Taieri 1908–1911 and Egmont (in the North Island) 1911–1912, never losing an election.
Mackenzie was also a notable explorer. He was the first person to try to map an overland route to Dusky Sound (1894–1896).
He crossed the land between Lake Te Anau and Lake Wakatipu in 1907. In January 1909 he was appointed Minister of Industries and Commerce, Tourist and Health Resorts, Scenery Preservation and State Forestry Departments in the government of Sir Joseph Ward.
In May he also became Minister of Agriculture with a seat in the Cabinet.
He was then successively Minister of Customs, Minister of Education and Postmaster-General. In May 1912 he succeeded Ward as Prime Minister and also served as Minister of Lands. Mackenzie"s Ministry was criticised by both the opposition and Liberal dissidents.
Liberal Member of Parliament Roderick McKenzie stated that Mackenzie"s ministers were political novices who had forsaken their liberal principles and John Millar should have been Ward"s successor as Prime Minister.
The Mackenzie government survived only until July 1912 when he lost a vote of no confidence and was appointed High Commissioner in London. In 1923 he supported Ernest Valentine Sanderson in establishing the Native Bird Protection Society (later the Royal Forest and Bird Protection Society of New Zealand) and was the Society"s first President.
Mackenzie died in Dunedin in 1930 and was buried in the Dunedin Northern Cemetery.
He was a member of expeditions to the Tautuku Forest (1883), the wild country between Milford Sound and Lake Te Anau (1888. Discovered the Sutherland Falls), and the Matterhorn Mountains (1888. Discovered a pass between Lake Manapouri and Hall Arm).
He served in this role until 1920 and was New Zealand delegate at the peace conferences with Austria, Bulgaria and Turkey in 1919, a member of the Dardanelles Commission and the Imperial War Graves Commission (later the Commonwealth War Graves Conmmission).
In March 1921 he was appointed member of the New Zealand Legislative Council for Otago.