Commissioned into the 1st Regiment of Guards, D'Oyly served with them during the 1799 Anglo-Russian expedition to the Netherlands in 1799. He returned to the Netherlands in the Walcheren Campaign of 1809. On 2 July 1811, both he and his brother Henry were promoted from captains to majors in the army. On 6 October 1812, he was given command of a company in the Guards as a brevet major after the death of Lt-Col. Colquitt. He then served under the Duke of Wellington in the British Army's campaign in the Spanish Peninsula and France, after which he was made a KCB. He again served under Wellington during the Hundred Days and was killed at the battle of Waterloo.