Most people don’t think of type 2 diabetes as a disease you can cure. Well, for some patients, it’s possible we can — with gastric bypass surgery. It can also lead to potentially life-saving weight loss, lower blood pressure, and relieve depression. In fact, in one study of 20,000 patients who had gastric bypass surgery, 84 percent found their type 2 diabetes completely cured.

There are downsides, however. Possible side effects include hernias, infection, blood clots, ulcers, and even death.

So, what if type 2 diabetes patients could get the same benefits of gastric bypass surgery without going under the knife?

Researchers from Brigham and Women’s Hospital (BWH) think they’re on track to figure out just how to do that. They published their findings Monday in Nature Materials.

A quick primer on gastric bypass surgery. Though the specifics can vary, the surgery basically “shrinks” the size of a person’s stomach by blocking off a large portion of the organ from the rest. Surgeons do the same in the small intestine.

With a stomach that can now only hold a very small amount of food, patients can no longer eat large meals. Additionally, because the food they do eat no longer travels through the entire small intestine, the body doesn’t absorb as many nutrients. Cumulative effect: weight loss.

People with type 2 diabetes have unusually high blood glucose (sugar) levels. Food consumption plays a major role in this elevation, and weight loss is one way to effectively treat it. So, people get gastric bypass surgery, lose weight, and reverse their diabetes. Cut and dry, right?

Not according to doctors. Many aren’t convinced that weight loss deserves all the credit for reversing type 2 diabetes in gastric bypass patients. In fact, they don’t really know why the surgery helps, just that it does.

The BWH team’s gastric bypass alternative could help, too. Here’s how it works.

Using an FDA-approved drug called sucralfate as a base, the team engineered a compound they call LuCI (Luminal Coating of the Intestine). Once ingested, the compound temporarily coats the inner lining of the intestine. This essentially replicates how the surgery makes part of the intestine unable to absorb nutrients. And it seems effective — within an hour of administration, LuCI lowered rats’ after-meal response to glucose by 47 percent.

“What we’ve developed here is essentially, ‘surgery in a pill,'” study co-lead author Yuhan Lee said in a press release. “We’ve used a bioengineering approach to formulate a pill that has good adhesion properties and can attach nicely to the gut in a preclinical model. And after a couple of hours, its effects dissipate.”

The pill, of course, isn’t quite ready to go on sale yet. Next, the researchers plan to test LuCI in diabetic and obese rats. If it works as hoped, the drug could one day provide a much-needed replacement for gastric bypass surgery in reversing type 2 diabetes.