Smoking is known to raise the risk of type-two diabetes
Giving up smoking sharply increases the risk of developing type-two diabetes, a US study suggests.
Researchers found quitters had a 70% increased risk of developing type-two diabetes in the first six years without cigarettes compared with non-smokers.
This is because they tend to put on weight.
However, the Annals of Internal Medicine study stressed that this should not be used as an excuse to carry on smoking.
The Johns Hopkins team also stress that smoking is a well known risk factor for type-two diabetes - as well as many other health problems, such as heart disease, stroke and cancer.
Researcher Dr Jessica Yeh said: "If you smoke, give it up. That's the right thing to do.
"But people have to also watch their weight."
The study, based on 10,892 middle aged adults who were followed for up to 17 years, found the risk of developing type-two diabetes was highest in the first three years after giving up smoking.
Around 1.8% of people giving up smoking developed type 2 diabetes each year during that period.
If quitters avoided developing the condition for 10 years, then their long-term risk returned to normal.
People who made no effort to give up smoking had a constant 30% increased risk of type-two diabetes compared with non-smokers.
Type-two diabetes means the body either fails to make enough of the hormone insulin, or cannot make proper use of it, leading to uncontrolled blood sugar levels.
Untreated this can cause serious disease, and complications such as blindness, kidney failure and nerve damage.
One of the major risk factors for the condition is being overweight, and the rise in obesity across the developed world has been blamed for a big increase in type-two diabetes.
The researchers found those who smoked the most and those who gained the most weight had the highest likelihood for developing diabetes after they quit.
On average, during the first three years of the study, quitters gained about 8.4lb (3.8kg).
The researchers said doctors should keep in mind the importance of weight control when counselling people about giving up smoking.
Quitters tend to put on weight because smoking acts to suppress appetite.
The use of nicotine replacement therapy has been shown to blunt the weight gain associated with giving up smoking.
Martin Dockrell, of the anti-smoking charity Ash, said: "The researchers are clear that smokers should quit but - especially if you are a heavy smoker or are already overweight - you might want to gently increase your exercise when you quit.
"If you are a smoker who is also overweight you should talk to your doctor about how to get the best from quitting.
"A little more exercise could help improve your sense of well being, reduce weight gain and undo some of the harm done by smoking leading to a healthier, happier you."
Natasha Marsland, of the charity Diabetes UK, said: "On no account should people use the theoretical results of this study as an excuse not to give up smoking.
"The health benefits of giving up smoking far outweigh the risk of developing type-two diabetes from modest, short-term weight gain."