From the Summary of Deaths: "Between 2006 and 2021, a total of 18,571 active-duty personnel have died while serving in the U.S. Armed Forces. (Throughout this In Focus, the designation 'active duty' refers to all active duty troops, including mobilized Reserve and Guard components.) Of those that died, 25% were killed while serving in OCO [Overseas Contingency Operations] operations--primarily within the territory of Iraq and Afghanistan. The remaining 75% died during operations classified in this In Focus as 'Non-Overseas Contingency Operations', or 'Non-OCO.'"
CRS In Focus, IF10899
Congressional Research Service: https://crsreports.congress.gov/