Even if you’re unfamiliar with the nitty-gritty of intermittent fasting, you’re probably aware of its broad strokes. By restricting your food intake a couple days a week (the 5:2 diet) or squishing all your meals into a short daily window (time-restricted fasting), you can lose weight. There’s also mounting evidence that regular bouts of fasting can lower your disease risks, improve your brain function, and even extend your life.

Experts say these diets shift the body’s use of energy in ways that improve cell health.

After going about 12 hours without food, your liver’s stores of glycogen — a form of energy — are depleted, and your body taps into its fat cells for energy, says Mark Mattson, a senior investigator with the National Institutes of Health (NIH) who has researched fasting and its effects (and who practices time-restricted fasting himself). This shift places stress on your cells — mild at first, but more significant the longer you go without eating — that can trigger all sorts of beneficial adaptations.

Some scientists say longer fasts may one day prove to be superior to shorter ones for health and longevity. How long are we talking? Think two or even three weeks at a stretch, says Dr. Luigi Fontana, a professor of medicine and director of the Healthy Longevity Research and Clinical Program at the University of Sydney in Australia.

These interventions are extremely powerful, and they can work in your favor or against you depending on how you do them.”

Going that long without food may sound dangerous. (And if you just winged it, it would be.) But Fontana says doing this kind of extended fast once every five or 10 years — with medical supervision — may help the body clear out a lot of its “cellular garbage.”

“We know that what leads to multiple diseases is the accumulation of molecular damage,” Fontana explains. The body’s biological detritus — the collected cellular junk that builds up over a lifetime — can reach a “critical point” at which cancer and age-related diseases form. But an extended fast may help clear away much of this waste, Fontana says.

How? When deprived of energy from food, the body has to rearrange its priorities. Fontana says one of the ways it does this is by initiating a cellular process called “autophagy,” which roughly translates to “self-devouring.” Basically, the body’s cells start to eat their own dysfunctional proteins, organelles, mitochondria, and any other disease-triggering waste that’s sitting around.

Autophagy is a natural function of healthy cells. But research suggests this function breaks down as an organism ages. Fontana says an extended fast seems to stimulate the process of autophagy.

In some cases, fasting may cause these old or junk-ridden cells to die off. That’s not a bad thing. “Fasting kills cells, but refeeding leads to new cells,” says Dr. Valter Longo, a professor of biological sciences and director of the Longevity Institute at the University of Southern California. “In mice, we saw a third of white blood cells die, but with refeeding, they not only went back to normal but were healthier — more like [the cells of] young mice,” he says, referring to a 2016 study that appeared in the journal Cancer Cell.

All this evidence suggests the human body is made to withstand — and even to thrive — when confronted with periodic stretches of foodlessness.

Not everyone is so gung-ho on fasting — for short periods or otherwise. For one, fasting could be very dangerous for people with a history of disordered eating or for women who are pregnant or nursing. And while there are a number of encouraging clinical trials showing that fasting diets can work when undergone with expert guidance, “more rigorous research is needed,” say the authors of a 2018 review of intermittent fasting diets for weight loss.

One of the biggest unanswered questions: How much fasting is optimal, and how much is too much? As of today, no one can say. While a 15-to-20-day fast may provide some dramatic health benefits, it undoubtedly carries significant (and potentially deadly) risks. Fasting for this amount of time could lead to serious liver damage, as well as muscle wasting and other symptoms of malnourishment — all of which are especially dangerous for the old or infirmed. Longo also points out that a person could pass out while driving during an extended fast, and that there could be additional risks for people taking prescription medications. “These interventions are extremely powerful, and they can work in your favor or against you depending on how you do them,” Longo says, adding that medical supervision is “a must” for fasting longer than a couple days.

For now, the clinical research on fasting more or less ends at five days. Most of the research in this area is Longo’s. He and colleagues have shown that people who fasted for five days once a month for three months lost weight and enjoyed reduced levels of some disease markers and associated hormones. But these people weren’t going wholly without food. Longo has developed a specialized diet — one that mimics the effects of fasting by cutting out most sugars and protein — which helped his study’s participants maintain adequate nutrition. (This “fasting mimicking diet” is now available commercially from a company called ProLon, which Longo helped launch. His share of the ProLon proceeds go to charity.)

Fontana says he can foresee a time when doctors recommend a two- or three-week fast to all healthy patients as a once-a-decade intervention. But a lot more research is needed to assess the short- and long-term safety of prolonged fasting. “There are still a lot of unanswered questions,” he says. “But based on what we know, taking in calories all day is not healthy.”