Researchers say patients should continue to take the drugs, which are commonly prescribed to older men, but warn they may need additional health checks.
The team stressed that current treatment guidelines do not need to change, based on their study of patient health records.
Men with enlarged prostates are commonly prescribed drugs called 5-alpha-reductase inhibitors that reduce the production of hormones called androgens. These help treat symptoms such as reduced urinary flow.
Previous short-term studies had suggested these drugs, which include finasteride and dutasteride, might affect metabolism and could reduce the body's response to insulin, an early sign of type 2 diabetes.
A team led by the University of Edinburgh and UCL studied health records from around 55,000 men in the UK, who had been prescribed 5-alpha-reductase inhibitors over an 11-year period.
They found the drugs were linked to an increase in risk of developing type 2 diabetes of about one third. This means that in a population of 500 men on this treatment for 20 years, 16 extra cases of diabetes are likely to develop.
A similar effect was seen when the team repeated the study with health records from a group of Taiwanese men.
The findings suggest men taking these medications may need additional health checks to monitor warning signs of diabetes so their prescriptions can be altered if necessary.
The research, published in the British Medical Journal, was funded by the Edinburgh and Lothians Health Foundation. Researchers from the Universities of Dundee and Newcastle and National Cheng Kung University in Taiwan also contributed to the study.
Professor Ruth Andrew, of the University/British Heart Foundation Centre for Cardiovascular Science at the University of Edinburgh, and senior author of the study said: "We found that commonly prescribed medications for prostate disease can increase risk of type 2 diabetes. These findings will be particularly important for health screening in older men who are already typically at a higher risk of type 2 diabetes. We will now continue our studies to better understand the long-term outcomes so we can better identify patients at greater risk."
Dr Li Wei, Associate Professor from UCL School of Pharmacy and the first author of the study said: "By studying real word data from different ethnic populations across the UK and Taiwan, we found that men being treated with dutasteride or finasteride for benign prostatic hyperplasia (BPH) have a roughly 30 per cent increased risk of developing diabetes. This demonstrates the importance of how routinely collected healthcare data can be used to identify significant clinical links. It is important that all patients are made aware of the risks and benefits of their medications. In this instance, men should be alerted to the increased risk of diabetes if they are taking these particular medicines for BPH, and should speak to their doctor if they are concerned."
Mr Laurence Stewart, a Consultant Urologist at Spire Murrayfield Hospital and honorary consultant at NHS Lothian, who was not directly involved in the study, said: "These findings should not be a major concern for men taking 5-alpha-reductase inhibitor medications. As doctors, we may need to review the way we monitor our patients to make sure we are extra vigilant for early signs of diabetes. Anyone with concerns should speak to their GP or Urologist for advice on alternative treatments."