The pancreas can be triggered to regenerate itself through a type of fasting diet, say US researchers.
Restoring the function of the organ - which helps control blood sugar levels - reversed symptoms of diabetes in animal experiments.
The study, published in the journal Cell, says the diet reboots the body.
Experts said the findings were "potentially very exciting" and could be "immensely" beneficial.
This is the latest study into the health benefits of the "fasting-mimicking diet".
People spend five days on a low calorie, low protein, low carbohydrate but high unsaturated-fat diet.
Then they have 25 days eating what they want - so overall it mimics periods of feast and famine.
The experiments were on mice, so the diet was modified for the different species.
But the results showed the diet regenerated a special type of cell in the pancreas called a beta cell.
These are the cells that detect sugar in the blood and release the hormone insulin if it gets too high.
Dr Valter Longo, from the University of Southern California, said: "Our conclusion is that by pushing the mice into an extreme state and then bringing them back - by starving them and then feeding them again - the cells in the pancreas are triggered to use some kind of developmental reprogramming that rebuilds the part of the organ that's no longer functioning."
There were benefits in both type-1 and type-2 diabetes in the mouse experiments.
Further tests on tissue samples from people with type-1 diabetes produced similar effects.
Dr Longo said: "Medically, these findings have the potential to be very important because we've shown - at least in mouse models - that you can use diet to reverse the symptoms of diabetes.
"Scientifically, the findings are perhaps even more important because we've shown that you can use diet to reprogram cells without having to make any genetic alterations."
Separate trials of the diet in people have been shown to improve blood sugar levels. The latest findings help to explain why.
Dr Emily Burns, research communications manager at Diabetes UK, said: "This is potentially very exciting news, but we need to see if the results hold true in humans before we'll know more about what it means for people with diabetes.
"People with type-1 and type-2 diabetes would benefit immensely from treatments that can repair or regenerate insulin-producing cells in the pancreas."
Follow James on Twitter.