The President of the United States may be the Commander in Chief, but not every president has served in the military. In the past, it was common for presidents to achieve high-ranking military positions before running for office. Some previous presidents have served as Generals of the Armies, leading the country through wartime. (Also see all US Presidents ranked by their age at election.)
Following are the 31 U.S. presidents who served in the military arranged in ascending order, along with the dates of their presidency, their military rank, and the branch of the military they last served in. When two or more presidents had the same rank, we ranked earlier presidents higher than later ones. We used the U.S. Department of Defense chart of officer insignia to find equivalencies between ranks for different branches of the military.
Why Are We Covering This

Military service used to be one of the key factors Americans looked at when voting for the president. Before Bill Clinton was elected in 1992, every single US president had served at least some time in the military. Today, it’s a much less critical factor for voters. Whether or not you think military service is important today for a president, serving in the military, or lack of military service, may influence a president’s geopolitical and foreign views.
31. James Buchanan

- Presidency: 1857-1861
- Rank: Private
- Branch: Pennsylvania Militia
30. George W. Bush

- Presidency: 2001-2009
- Rank: First Lieutenant
- Branch: Air National Guard
29. George H.W. Bush

- Presidency: 1989-1993
- Rank: Lieutenant
- Branch: U.S. Navy Reserve
28. Ronald Reagan

- Presidency: 1981-1989
- Rank: Captain
- Branch: United States Army Reserve
27. John F. Kennedy

- Presidency: 1961-1963
- Rank: Lieutenant
- Branch: U.S. Navy Reserve
26. Jimmy Carter

- Presidency: 1977-1981
- Rank: Lieutenant
- Branch: U.S. Navy
25. William McKinley

- Presidency: 1897-1901
- Rank: Captain
- Branch: U.S. Army
24. Abraham Lincoln

- Presidency: 1861-1865
- Rank: Captain
- Branch: Illinois State Militia
23. John Tyler

- Presidency: 1841-1845
- Rank: Captain
- Branch: Virginia Militia
22. Gerald Ford

- Presidency: 1974-1977
- Rank: Lieutenant Commander
- Branch: U.S. Navy Reserve
21. Millard Fillmore

- Presidency: 1850-1853
- Rank: Major
- Branch: New York Militia
20. Richard Nixon

- Presidency: 1969-1974
- Rank: Commander
- Branch: U.S. Navy Reserve
19. Lyndon B. Johnson

- Presidency: 1963-1969
- Rank: Commander
- Branch: U.S. Navy Reserve
18. Harry S. Truman

- Presidency: 1945-1953
- Rank: Colonel
- Branch: United States Army Reserve
17. Theodore Roosevelt

- Presidency: 1901-1909
- Rank: Colonel
- Branch: U.S. Army
16. James K. Polk

- Presidency: 1845-1849)
- Rank: Colonel
- Branch: Tennessee Militia
15. James Monroe

- Presidency: 1817-1825
- Rank: Colonel
- Branch: Virginia Militia
14. James Madison

- Presidency: 1809-1817
- Rank: Colonel
- Branch: Virginia Militia
13. Thomas Jefferson

- Presidency: 1801-1809
- Rank: Colonel
- Branch: Virginia Militia
12. Benjamin Harrison

- Presidency: 1889-1893
- Rank: Brigadier General
- Branch: U.S. Army
11. Chester A. Arthur

- Presidency: 1881-1885
- Rank: Brigadier General
- Branch: New York Militia
10. Andrew Johnson

- Presidency: 1865-1869
- Rank: Brigadier General
- Branch: U.S. Army
9. Franklin Pierce

- Presidency: 1853-1857
- Rank: Brigadier General
- Branch: U.S. Army
8. James A. Garfield

- Presidency: 1881
- Rank: Major General
- Branch: U.S. Army
7. Rutherford B. Hayes

- Presidency: 1877-1881
- Rank: Major General
- Branch: U.S. Army
6. Zachary Taylor

- Presidency: 1849-1850
- Rank: Major General
- Branch: U.S. Army
5. William Henry Harrison

- Presidency: 1841
- Rank: Major General
- Branch: U.S. Army
4. Andrew Jackson

- Presidency: 1829-1837
- Rank: Major General
- Branch: U.S. Army
3. Dwight D. Eisenhower

- Presidency: 1853-1961
- Rank: General of the Army
- Branch: U.S. Army
2. Ulysses S. Grant

- Presidency: 1869-1877
- Rank: General of the Armies
- Branch: U.S. Army
1. George Washington

- Presidency: 1789-1797
- Rank: General of the Armies
- Branch: U.S. Army