Until Australia became a Federation in 1901, each of the six colonies was responsible for its own defence. From 1788 until 1870 this was done with British regular forces. In all, 24 British infantry regiments served in the Australian colonies. Each of the Australian colonies gained responsible government between 1855 and 1890, and while the Colonial Office in London retained control of some affairs, and the colonies were still firmly within the British Empire, the Governors of the Australian colonies were required to raise their own colonial militias. To do this, the colonial Governors had the authority from the British crown to raise military and naval forces. Initially these were militias in support of British regulars, but British military support for the colonies ended in 1870, and the colonies assumed their own defence. The separate colonies maintained control over their respective militia forces and navies until 1 March 1901, when the colonial forces were all amalgamated into the Commonwealth Forces following the creation of the Commonwealth of Australia. Colonial forces, including home raised units, saw action in many of the conflicts of the British Empire during the 19th century. Members from British regiments stationed in Australia saw action in India, Afghanistan, the New Zealand Wars, the Sudan conflict, and the Boer War in South Africa.
Despite an undeserved reputation of colonial inferiority, many of the locally raised units were highly organised, disciplined, professional, and well trained. For most of the time from settlement until Federation, military defences in Australia revolved around static defence by combined infantry and artillery, based on garrisoned coastal forts; however, in the 1890s improved railway communications between all of the eastern mainland colonies (Queensland, New South Wales, Victoria, and South Australia), led Major General Bevan Edwards, who had recently completed a survey of colonial military forces, to state his belief that the colonies could be defended by the rapid mobilisation of standard brigades. He called for a restructure of colonial defences, and defensive agreements to be made between the colonies. He also called for professional units to replace all of the volunteer forces.
By 1901, the Australian colonies were federated and formally joined together to become the Commonwealth of Australia, and the federal government assumed all defensive responsibilities. The Federation of Australia came into existence on 1 January 1901 and as of that time the constitution of Australia stated that all defence responsibility was vested in the Commonwealth government. Co-ordination of Australia-wide defensive efforts in the face of imperial German interest in the Pacific Ocean was one of the main reasons for federation, and so one of the first decisions made by the newly formed Commonwealth government was to create the Department of Defence which came into being on 1 March 1901. From that time the Australian Army came into being under the command of Major General Sir Edward Hutton, and all of the colonial forces, including those then on active service in South Africa, transferred into the Australian Army.