A new study published in The BMJ has found that antidepressant use may be associated with weight gain over time.

“Patients who were normal weight were more likely to transition to overweight, and overweight patients were more likely to transition to obesity if they were treated with antidepressants,” said study co-author Rafael Gafoor, a primary care and public health researcher at King’s College London, in an email to TIME.

The researchers used data from the UK Clinical Practice Research Datalink, a large collection of electronic health records. Their analysis included almost 295,000 people of all different weights. Researchers then monitored the health records for antidepressant use and weight gain over time, accounting for other factors that could affect weight gain, like age, chronic disease diagnoses, smoking status and taking other drugs.

Get our Health Newsletter. Sign up to receive the latest health and science news, plus answers to wellness questions and expert tips. Please enter a valid email address. Sign Up Now Check the box if you do not wish to receive promotional offers via email from TIME. You can unsubscribe at any time. By signing up you are agreeing to our Terms of Use and Privacy Policy . This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply. Thank you! For your security, we've sent a confirmation email to the address you entered. Click the link to confirm your subscription and begin receiving our newsletters. If you don't get the confirmation within 10 minutes, please check your spam folder.

Those who were prescribed antidepressants during the first year of the study were 21% more likely to have gained at least 5% of their starting body weight over the 10 years of follow-up, compared to people not taking the drugs. The risk of weight gain appeared to be greatest in the second and third years of treatment and remained elevated for six years after beginning a course of treatment. “[It] may take some time for weight gain to be noticeable and recorded into medical records,” Gafoor says.

Some drugs were more strongly associated with weight gain than others, the study found. People taking mirtazapine (or Remeron), which is now rarely prescribed, had a 50% higher risk of gaining at least 5% of their body weight, compared to people who were not taking antidepressants. Citalopram (a commonly prescribed drug sold under the brand name Celexa) was associated with a roughly 26% higher risk of the same.

MORE: Is Ketamine A New Hope For Depression?

The study comes with many caveats. To be included, people had to have at least three body mass index measurements on record. This may have skewed the data somewhat, since people with chronic illnesses are more likely to see doctors regularly, and thus have comprehensive BMI data on record; these patients may also be on medical regimens that influence their diet and weight management. The authors also note that the findings were based on antidepressant prescriptions, but it wasn’t possible to monitor whether people were actually taking drugs as directed.

It’s also possible that depressive symptoms, such as increased appetite and decreased motivation to exercise, were at least partially to blame for weight gain, independent of antidepressant use. The current study, however, separately accounted for depression diagnoses, and previous smaller, short-term studies have also linked antidepressants themselves to weight gain.

The risk of weight gain should not necessarily discourage people from taking antidepressants, Gafoor says, but patients should discuss the risk of weight gain with their doctors when beginning a new treatment plan, and potentially develop long-term strategies for keeping it in check.

“A variety of factors need to be taken into account when prescribing any given antidepressant,” Gafoor says, “so the best advice is to have an open, informed conversation with your prescriber if weight gain (or any other side effect) is bothersome.”

Write to Jamie Ducharme at jamie.ducharme@time.com.