For several years, researchers have struggled to explain the obesity paradox. This is the observation that, after being diagnosed with cardiovascular disease, people who are overweight or obese live longer than people who have a healthy weight.

How is it possible for those extra pounds to provide extra years of life? The answer, it turns out, is simple.

They aren’t.

A new study shows what’s really going on: People who are overweight or obese are being diagnosed with cardiovascular disease at younger ages. Although they do spend more years living with the disease than their slimmer peers, they do not live longer overall.

Indeed, one of the main effects of carrying around too much excess weight is that you get fewer years of disease-free life.

A team of researchers led by Dr. Sadiya Khan of Northwestern University’s Feinberg School of Medicine figured this out by examining data from the Cardiovascular Disease Lifetime Risk Pooling Project.

They pulled medical information on 190,672 Americans who did not have cardiovascular disease when they began being tracked by researchers. All of them had their height and weight measured at least once, and all of them were followed for at least 10 years. Altogether, they provided researchers with 3.2 million years of health data.

The researchers grouped the study participants according to their age and their weight status. Starting with people between the ages of 40 and 59, they saw that those who were overweight or obese had a higher risk of a heart attack, stroke or congestive heart failure than did those with a normal weight.

For instance, among middle-aged men, 37 percent of those who were overweight (that is, with a body mass index between 25 and 29.9) experienced some type of cardiovascular event after joining a study. So did 47 percent of men who were obese (with a body mass index between 30 and 39.9) and 65.4 percent of those who were morbidly obese (with a BMI of 40 or above). By comparison, 32 percent of men with a BMI in the normal range (between 18.5 and 24.9) suffered a cardiovascular event.

Among middle-aged women, 27.9 percent of those who were overweight had a heart attack, stroke or congestive heart failure after joining a study, as did 38.8 percent of those who were obese and 47.6 percent of those who were morbidly obese. Among women with a normal weight, 21.5 percent experienced one of these cardiovascular events.

After adjusting the data to account for risk factors like age, race, ethnicity and smoking status, Khan and her colleagues found that the higher the BMI, the greater the lifetime risk of some type of heart problem. For example, compared to middle-aged men with a normal BMI, the risk of a heart attack (either fatal or nonfatal) was 18 percent higher for men who were overweight, 42 percent higher for men who were obese, and 98 percent higher for men who were morbidly obese.

For middle-aged women, the risk of a heart attack was 42 percent higher for those who were overweight, 75 percent higher for those who were obese and 80 percent higher for those who were morbidly obese.

The researchers found that middle-aged adults with a normal weight lived the most years free of cardiovascular disease. For instance, men who were morbidly obese experienced their first cardiovascular event 7.5 years sooner than men with a normal BMI. For women, the difference was 7.1 years.

In addition, a normal weight was associated with a longer life overall. Middle-aged men with a normal BMI lived 5.6 years longer than men who were morbidly obese, while women with a normal BMI lived 2 years longer than women who were morbidly obese.

All of these patterns were similar in younger and in older adults, the researchers found.

By looking at people’s health over a longer period of time — not just after they’ve been diagnosed with a heart problem — the true significance of the obesity paradox comes into view.

“The obesity paradox … appears largely to be caused by earlier diagnosis of CVD,” the researchers wrote, using an abbreviation for cardiovascular disease.

“Adults who were obese had an earlier onset of incident CVD, a greater proportion of life lived with CVD morbidity (unhealthy life years), and shorter overall survival compared with adults with normal BMI,” they concluded.

The study was published in the journal JAMA Cardiology.