# List of prime ministers of Canada by military service

There are seven prime ministers of Canada with military service. Four prime ministers served with the sedentary militias or active militias of the Province of Canada, or the succeeding Canadian Confederation during the 19th century. Two served with the Canadian Expeditionary Force (CEF) during First World War. The last prime minister to serve in the military was Pierre Trudeau, who joined the Canadian Officers' Training Corps during the Second World War.
The prime ministers with military experience have only served with the land forces of Canada, the active militias/Canadian Army, or the CEF. No prime minister has served in the other branches of the Canadian Armed Forces: the Royal Canadian Air Force and Royal Canadian Navy. Lester B. Pearson is the only prime minister to serve in the British Army, having transferred to the Royal Flying Corps from the CEF.
In addition to military service, two prime ministers served as a defence minister prior to their premiership. Although John A. Macdonald was the first prime minister of confederated Canada, he previously served as the minister of militia and defence for the Province of Canada. Kim Campbell is the only prime minister to serve as prime minister, and simultaneously hold the defence portfolio (as the minister of national defence).
The prime minister is not commander-in-chief of the Canadian Armed Forces, rather the role is held by the monarch of Canada and is held on behalf of the monarch by the governor general of Canada.
| Prime Minister | Service | Rank | Active service |
| Sir John A. Macdonald | Sedentary militia | Private | Kingston during Upper Canada Rebellion 1837; Minister of Militia and Defence 1860-1867 |
| Alexander Mackenzie | Active militia | Major | None; member of militia in Lambton, Ontario (1866–1874) |
| Sir John Joseph Caldwell Abbott | Active Militia | commanding officer (Lieutenant Colonel?) | None; officer of 11th Argenteuil Battalion militia in Montreal area (1866-1874?) |
| Sir John Sparrow David Thompson | none | none | none |
| Sir Mackenzie Bowell | Active militia | Lieutenant Colonel | Canadian militia posted along the border during the American Civil War; member of 49th (Hastings) Battalion of Rifles militia unit in North Hastings, Ontario (1867–1872); Minister of Militia and Defence 1892 and 1896 (acting) |
| Sir Charles Tupper | none | none | none |
| Sir Wilfrid Laurier | none | none | none |
| Sir Robert Laird Borden | none | none | none |
| Arthur Meighen | none | none | none |
| William Lyon Mackenzie King | none | none | none |
| Richard Bedford Bennett | none | none | none |
| Louis St. Laurent | none | none | none |
| John Diefenbaker | Canadian Expeditionary Force | Lieutenant | Served during World War I (1916–1917) in Britain as member of 196th Battalion (Western Universities), CEF |
| Lester Bowles Pearson | Canadian Expeditionary Force | Lieutenant | Served during World War I in Greece and Egypt as member of Canadian Army Medical Corps and later in the Royal Flying Corps as Pilot (1915–1918) in Britain |
| Pierre Trudeau | Canadian Army | Officer cadet | None; Served in Canadian Officers' Training Corps from 1943 to 1945 in Montreal during World War II, but never deployed overseas |
| Joe Clark | none | none | none |
| John Turner | none | none | none |
| Brian Mulroney | none | none | none |
| Kim Campbell | none | none | none; Minister of National Defence 1993 |
| Jean Chrétien | none | none | none |
| Paul Martin | none | none | none |
| Stephen Harper | none | none | none |
| Justin Trudeau | none | none | none |
| Mark Carney | none | none | none |