A large new study found that people who lost significant amounts of weight through bariatric surgery gained a striking benefit: Their likelihood of developing cancer fell sharply.

The study, published on Friday in JAMA, followed more than 30,000 adults with obesity for about a decade. It found that those who underwent weight loss surgery had a 32 percent lower risk of developing cancer and a 48 percent lower risk of dying from the disease, compared with a similar group of people who did not have the surgery. On average, the people who had weight loss surgery lost about 55 pounds more than those who did not over the course of the study. The researchers found that the more weight people lost, the more their cancer risk fell.

Obesity is a strong driver of cancer risk. Health authorities have linked excess weight to higher rates of many cancers. The new study is among the largest and most rigorous to suggest that the increased risk can be reversed in people who lose substantial amounts of weight.

While the new research focused on weight loss through bariatric surgery, the authors of the study speculated that the benefit would apply to weight loss through other methods as well, such as diet and exercise or the use of weight loss medications. Dr. Steven E. Nissen, a co-author of the study, said the findings "provide one more reason why people who are obese should lose weight."

"It's an important public health message," said Nissen, the chief academic officer of the Heart, Vascular and Thoracic Institute at the Cleveland Clinic. "I think a lot of the public doesn't understand or realize that obesity is such a strong risk factor for cancer, and they certainly don't understand that it's reversible."

One expert who was not involved in the study, Dr. Ania Jastreboff, said that it demonstrates that treating obesity and achieving "clinically meaningful" weight reductions can improve health outcomes for patients. "That's a really important finding," said Jastreboff, an associate professor at the Yale School of Medicine and the director of weight management and obesity prevention at the Yale Stress Center.

According to the Centers for Disease Control and Prevention, obesity is a leading cause of preventable cancers, along with smoking, heavy drinking and exposure to ultraviolet radiation. People who are overweight or obese have a higher risk of developing 13 different types of cancer, including endometrial, breast, kidney, liver, esophageal and colorectal. The C.D.C. estimates that the 13 types of cancer linked to obesity make up 40 percent of all cancers diagnosed in the United States each year.

It is not entirely clear why obesity seems to promote cancer, but one potential factor is inflammation. Studies show that fat cells spew into the bloodstream a variety of inflammatory proteins known as cytokines, which have been found to stimulate cancer cells. Many scientists believe this chronic state of inflammation caused by fat cells is also one of the reasons people with obesity have higher rates of complications from COVID-19.

Fat cells are often thought of as being inert — "that they're just sitting there and not doing anything," Nissen said. "But, in fact, they're metabolically active. We think that the chronic inflammation produced by obesity, by these very metabolically active fat cells, is one of the mechanisms by which cancer is induced."

According to the C.D.C., people with obesity tend to have higher levels of hormones such as insulin and insulin-like growth factor-1, or IGF-1, which can stimulate the development of colon, kidney, prostate and endometrial cancers.

Bariatric surgery can lead to substantial weight loss. Though some patients end up regaining some of the weight that they lost, studies show that most people who undergo bariatric surgery are able to sustain a more than 20 percent reduction in their body weight a decade after their procedure. That is much greater than what people with obesity can typically lose and maintain through diet and exercise alone.

For the new study, Nissen and his colleagues wanted to see how that amount of weight loss would affect cancer rates. They recruited 5,053 people with obesity who had undergone bariatric surgery at the Cleveland Clinic and followed them. Each patient was "matched" to five other patients who were similar in many respects. They were about the same age, sex and race, and they had similar medical histories and body mass indexes, but they did not undergo weight loss surgery.

All told, there were more than 30,000 participants in the study, which included 25,265 people in the control group. Both groups had a median age of 46 and a median body mass index of 45, which the C.D.C. categorizes as "severe" obesity. That is the equivalent of someone who is 5 feet 8 inches tall weighing about 300 pounds. According to the C.D.C., someone with a B.M.I. between 25 and 30 is considered overweight and someone with a B.M.I. above 30 is classified as obese. A large nationwide study published last year found that about 42 percent of adults in the United States were obese and roughly 9 percent had severe obesity.

Not every person with obesity can have weight loss surgery. In general, to qualify for it, patients must have a B.M.I. of at least 40, or a B.M.I. of 35 or above along with at least one obesity-related condition, such as Type 2 diabetes, hypertension or heart disease. In the new study, people who underwent surgery had either gastric bypass or sleeve gastrectomy procedures.

After a decade, the patients who had the surgery had lost an average of about 61 pounds, while those in the control group (who were advised by their doctors to try to lose weight on their own) had lost an average of six pounds. Slightly less than 3 percent of patients who had surgery developed cancer, compared with roughly 4.9 percent of those in the nonsurgical group — equivalent to a 32 percent reduction in risk for those who had surgery.

In general, the data suggested that patients needed to lose a large amount of weight, at least 20 to 25 percent of their body weight, to see a beneficial change in their cancer risk, said Dr. Ali Aminian, the lead author of the study and the director of the Bariatric and Metabolic Institute at the Cleveland Clinic. The reduction in risk was particularly significant for endometrial cancer, which has the strongest association with obesity.

Aminian and several of the study's authors reported receiving research grants or consulting fees from Medtronic, a company that makes devices used in weight loss surgery. Nissen disclosed receiving research funding from companies that develop weight loss drugs, including Novartis and Eli Lilly.

Nissen said that while the new study focused on bariatric surgery, the message was that people should seek to lose weight in whatever way they could, whether through diet and exercise or with help from medical therapies. About a quarter million people in the United States have bariatric surgery every year, Nissen said, "but there are probably 100 million people that are obese."

"We cannot do bariatric surgery on a third of the U.S. population," Nissen added. "It's just not feasible."

Obesity is often framed as a failure of willpower. But Jastreboff at Yale noted that since 2013, the American Medical Association has recognized obesity as a chronic disease. She stressed that, as with any other chronic disease, people with obesity should not feel that they must struggle with it on their own. Instead, they should seek help from a doctor or a health care provider who can offer them safe and effective treatments.

"When a patient comes to see me for their obesity, one of the first things I say is that this is not their fault, this is not their choice," she said. "We should not blame patients for having the disease of obesity, in the same way that we do not blame our patients for having diabetes or high blood pressure."