Obesity and lack of fitness raise the risk of illness by impacting negatively on the body's internal chemistry, research suggests.
A US team found levels of white blood cells were highest in men who were unfit and overweight.
White blood cells are key to fighting infection, but high levels can be a sign of inflammation, which is linked to coronary heart disease.
The study appears in the British Journal of Sports Medicine.
A team from the Pennington Biomedical Research Center carried out tests on 452 healthy men who were taking part in a long-term study of fitness.
Blood tests were taken, and analysed for their content of various types of white blood cell.
After taking account of age, the researchers found that all groups of white blood cell were lowest in the men who were most physically fit.
The greater proportion of body fat a man had, the higher his white blood cell count was.
Total white cell count was highest in men who had a combination of higher body fat and lower levels of physical fitness.
Levels were also high among men with lower body weight but lower levels of fitness.
However, a high degree of physical fitness negated the effect of extra body fat.
White cell counts tend to rise after a bout of vigorous exercise, but the researchers said regular exercise might condition the body to respond more efficiently to the physical demands made of it.
Lead researcher Professor Tim Church said it was clear that inflammation played a key role in heart disease and other illnesses, but the factors which drove it were still relatively unclear.
He said: "There is nothing worse than a risk factor that an individual cannot modify, but here are two risk factors - obesity and fitness - which they can do something about."
June Davison, cardiac nurse at the British Heart Foundation, said: "These findings add to evidence that regular physical activity and keeping close to a healthy weight have huge benefits for your heart health."
And John Brewer, performance director at the Lucozade Sport Science Academy in Slough, stressed that an unhealthy lifestyle posed "real dangers" to health.
He said: "Whilst studies like this one, and initiatives from the government and health-promotion agencies, can raise awareness of the risks, ultimately it is down to individuals to chose a lifestyle and habits that give them the best chance of leading a healthy, active life."