Born the son of General Thomas Edmond Knox, William Knox was commissioned into the Royal Artillery in 1867. He took part in Expedition to Abyssinia in 1868, in the Third Anglo-Ashanti War in 1874 and in the Russo-Turkish War in 1877. He also fought in the Second Anglo-Afghan War in 1878, was promoted to captain on 23 January 1879, and fought in the Anglo-Zulu War later the same year. Promoted to major on 21 April 1880, he was appointed Commander of the Royal Horse Artillery at Curragh Camp that year, and promoted to lieutenant-colonel on 2 October 1891. After promotion to colonel on 27 August 1898, he then took part in the Second Boer War (1899–1902), being present at the defence of Ladysmith in 1900.