As a young man, he joined the life regiment of King Frederick William I. On 4 August 1740 he became second lieutenant and joined the first battalion of the life regiment of the new king Frederick II. There he received the rank of a captain. In 18 June 1745, he became Chief of Staff of the Guard, with the rank of lieutenant colonel. In the First Silesian War, he led his own grenadier battalion composed of companies from Regiments No. 5 Wedel and No. 20 (Voigt). Hagen received command of a grenadier battalion in the Second Silesian War, this time from companies of Regiments No. 13 Truchsess and No. 37 (Moulin).