It pays to be fit in middle age.

This is according to a study presented at the American Heart Association’s Quality of Care and Outcomes Research 2012 Scientific Sessions.Because more physically fit middle-aged men and women had significantly lower health care costs after age 65.

For this study, researchers recruited 20,489 healthy men and women, whose average age at the start of the study was 51. All the participants underwent treadmill testing to determine their aerobic capacity. The participants’ Medicare and other insurance costs were examined when their average age was 72.

After controlling for risk factors such as smoking, high blood pressure, and obesity, researchers found that better midlife fitness predicted lower medical care costs. Average annual medical claims for the least fit men were about 36% higher than those for the fittest men – $5,134 compared to $3,277 – while health care costs for the least fit women were about 40% higher than those for the fittest women – $4,565 compared to $2,755.