The numbers affected have risen 65 per cent in a decade which is mainly due to rising levels of obesity.
There is no cure and many patients suffer severe complications including kidney disease and foot amputations because their blood sugar levels are so out of control.
Today's research, published in the journal Cell, showed that the five-day diet appeared to "rescue" mice from type 2 and the less common type 1 diabetes.
The mice were injected with certain chemicals which caused diabetes.
This is a very interesting and well done study in mice with findings that may in future have implications for the treatment of diabetes.
They were then starved and re-fed, three times, and the disease began to reverse.
The scientists want to test the diet on humans but, rather than being starved, they will be given between 700 and 1100 calories a day.
They would mostly consume soups, energy drinks and protein bars for five days before returning to their usual eating habits.
Lead researcher Professor Valter Longo said: "Our conclusion is that by pushing the mice into an extreme state and then bringing them back - by starving 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.
"By activating the regeneration of pancreatic cells, we were able to rescue mice from late-stage type 1 and type 2 diabetes.
"We also reactivated insulin production in human pancreatic cells from type 1 diabetes patients."
He said the findings of this experiment will hopefully lead to a much larger trial on humans, approved by the Food and Drugs Administration - the US drugs watchdog.
"Hopefully, people with diabetes could one day be treated with an FDA-approved fasting-mimicking diet for a few days each month and gain control over their insulin production and blood sugar," he added.
Professor Anne Cooke, an expert in immunobiology at the University of Cambridge, said: "This is a very interesting and well done study in mice with findings that may in future have implications for the treatment of people suffering from type 2 diabetes and also potentially type 1 diabetes.
"This is good science and does give promise for the future treatment of diabetes, but we need further studies to see whether this works in people as well as it has in mice."
Only yesterday researchers at Imperial College London announced they had developed a jab which reduced the chance of developing the illness by 80 per cent.
The daily injection appears to prevent the condition developing in at-risk patients who had very high blood sugar levels.