Abstract
Background:
Patients with type 2 diabetes (T2DM) are at risk of developing urinary tract infections (UTIs). Sodium-glucose cotransporter-2 inhibitors (SGLT2i) are a common medication associated with UTIs in these patients. However, emerging data show that other medications may be more frequently prescribed prior to UTI diagnosis.
Objectives:
Explore the correlation of newly prescribed medications in patients with the diagnosis of T2DM prior to an incidence of UTI and compare it to those without a UTI.
Design:
This observational case-control study aimed to explore the correlation between the incidence of UTIs in patients with T2DM and new prescription medication fills.
Methods:
Data were retrieved from national prescription and medical claims database IQVIA PharMetric® Plus for Academics between 2018 to 2021. The exposed cohort included patients with T2DM and an encounter for UTI. The comparator cohort was developed using propensity score matching and consisted of patients with T2DM and a health care encounter, but without a diagnosis of UTI.
Results:
A total of 31,746 patients met study criteria, with 15,873 in both the exposed and matched comparator cohorts. The medications with the largest percentage point difference were opioids at 3.70 (p-value <0.001), statins at 3.42 (p-value <0.001), amoxicillin at 2.48 (p-value <0.001), metformin at 2.45 (p-value <0.001), and PPIs at 2.19 (p-value <0.001). SGLT2i were the 19th most prescribed medication class.
Conclusion:
Opioids, statins, amoxicillin, metformin, and PPIs were the top 5 medications prescribed prior to the UTI event based on percentage point difference. SGLT2i were not in the top 10 medications initiated prior to UTI. This adds to existing literature that other new start medications may be correlated with a higher risk of developing a UTI such as opioids and PPIs than SGLT2 inhibitors in patients with T2DM.
Plain language summary
Why was the study done? Individuals with high blood sugars are at a higher risk of developing a bladder infection. There is not a lot of information describing medications that can also increase the chances of developing a bladder infection in individuals with high blood sugar levels. This can be an issue when providers decide on which medications they want to prescribe to patients with high blood sugar levels.
What did the researchers do? The research team looked at all the medications prescribed to patients with high blood sugars who have not had a bladder infection before and compared the list of medications to patients with high blood sugars who developed a bladder infection. The patients used in both groups were similar in age, sex, and health.
What did the researchers find? They found several medication classes that people who developed bladder infections were prescribed more commonly than those who did not develop a bladder infection. The top 5 medication classes seen most commonly prescribed in patients with bladder infections included pain medications such as opioids, cholesterol lowering medications such as statins, an antibiotic called amoxicillin, a blood sugar lowering medication called metformin, and stomach pills called proton pump inhibitors which are commonly found over the counter.
What do the findings mean? This study wants to inform providers about the concerns and possible risks by prescribing some common medications to individuals who are already at a higher risk of developing a bladder infection. Some of these medications are not commonly thought of increasing the risk of bladder infection, so it is important to take all medications into consideration, regardless of what they are for, when prescribing something new to a patient with high blood sugars.
Introduction
In the United States, the most common type of bacterial infections are urinary tract infections (UTIs). These infections tend to have a higher prevalence in patients with type 2 diabetes (T2DM) compared to the general population.1,2 There are multiple mechanisms that increase the incidence of UTIs in this population including immune function impairment, dysfunctional bladder emptying, and higher glucose levels in the urine.1,2 Among those with T2DM, women, older adults, and pregnant females are also at a higher risk of UTIs due to their anatomical structures.3–7
A commonly prescribed medication class that is thought to increase the risk of these infections are sodium-glucose cotransporter-2 inhibitors (SGLT2i). This is attributed to their mechanism of action, which involves an increase in the excretion of glucose through the urine. Population-based cohorts across different nations have found that SGLT2i are not at an increased risk of UTI development and consider incidence similar to other traditional T2DM medications such as metformin, insulin, dipeptidyl-peptidase-4 inhibitors (DPP4i), and glucagon-like peptide 1 receptor agonists (GLP1-RAs).8–15 Systematic reviews and meta-analyses have reported mixed data regarding increased risk of developing UTIs among those initiating SGLT2i compared to the other antidiabetic agents with the majority of the existing studies showing no increased risk.16–23 Outside of SGLT2i and antihyperglycemic agents, other medication classes prescribed to those with T2DM are often not thought to increase the risk of UTIs and are overlooked.
Outside of T2DM medications and patients, studies have noted an increased risk of UTIs with the use of antihypertensive agents, antipsychotic agents, prior antibiotic use, and opioids. Antihypertensive agents like angiotensin-converting enzyme inhibitors (ACEi) and angiotensin II receptor blockers (ARB) can reduce urine output and bacterial clearance from the urinary tract upon initiation, thus possibly increase risk of UTIs.24,25 When comparing these classes of medications to other antihypertensive agents, the evidence did not show significant increase or decrease in UTI incidence or antibiotic therapy across multiple antihypertensive classes including ACEi and ARB. 26
Both typical and atypical antipsychotics were reported to increase UTIs in older adults. However, it cannot be determined if the occurrence can be attributed to antipsychotic use or the underlying disease or other comorbid conditions such as delirium.27,28 Prior antibiotic use is a known factor to increase the risk of UTI. This is due to disruption in normal urogenital flora, increased resistance, and colonization of pathogens.29–32 For opioids, risk of UTI is thought to be associated with immunosuppressive properties.33–41 This was reported in an observational study that was not matched against a comparator group of individuals without UTIs. 42
More robust data is needed to identify medication classes outside of SGLT2i to potentially reduce overall occurrence of UTI development in those with T2DM. This study aims to build upon existing studies to evaluate if there is further correlation in the risk of developing UTIs for patients with T2DM with the initiation of other medications outside of SGLT2i, while also using a comparator group.
Methodology
This observational case-control study utilized prescription and medical claims data obtained from IQVIA PharMetric® Plus for Academics 43 to determine eligible patients from 2018 to 2021. Data access was granted through purchasing a license from IQVIA PharMetric® Plus for Academics to receive random data sample. Patients were included in the study based on the following criteria: age 18–80 years and ICD-10 codes with the prefix E11 pertaining to T2DM. The upper limit for age was set at 80 based on the data use agreement with concerns about small numbers and increased risks of patient re-identification. Patients were excluded from the study if they had ICD-10 codes for active pregnancy, indwelling catheter, paraplegia/quadriplegia, sexually transmitted chlamydial diseases, disorder of the kidney and ureter not elsewhere classified, and trichomoniasis (ICD-10 codes listed in Supplemental Appendices 1 and 2), as these conditions may put a patient at an increased risk of developing a UTI. Patients with UTI encounters that were categorized as home health or dialysis were also excluded. Medication classes of interest can be found in Table 1. These medications were selected based on a report of the most commonly filled medications for the cohorts, previous literature,24–42 and clinical decision-making. Classes identified by medical decision-making were selected based on other medications of similar interest already being investigated.
Medication classes assessed.
Top 30 most filled medications from all patients.
Literature supportive medication classes.
Clinical decision-making.
The exposed cohort consisted of patients having an ICD-10 code pertaining to UTI. Next, they were evaluated for the initiation of new medication(s) filled outpatient within 0–6 months prior to UTI encounter. A new medication was classified as any medication that was not previously filled 12 months before the encounter for T2DM. The comparison cohort was created through propensity score matching based on age, sex, and insurance type. Propensity score matching was conducted for six subgroups based on insurance type and gender. 44 For each group, the propensity score model included age, Charlson comorbidity score, treatment location, geographic location. Our propensity score matching included 1:1 nearest neighbor matching without replacement. In Supplemental Appendix 3, we show standardized mean differences for each observable confounder included in the model prior to and following matching. These patients were also evaluated for new medication(s) filled prior to the encounter that did not result in a UTI.
Analysis for this project was generated using Stata SE v18 statistical software College Station, TX, USA. The percentage point difference was used to measure the patient’s likelihood of newly filling a certain medication class prior to developing a UTI. Chi-square tests were used to assess this difference for each of the medication classes. p values of ⩽0.05 were deemed to be statistically significant. The reporting of this study conforms to the STROBE statement for case-control studies. 45
Results
A total of 31,746 patients met study inclusion and exclusion criteria. The exposed cohort consisted of 15,873 patients with an encounter for a UTI. The matched cohort identified through propensity score matching that did not have an encounter for UTI consisted of 15,873 patients. Baseline demographics are displayed in Table 2. There were no significant differences between groups following propensity score matching (located in Supplemental Appendix 3).
Patient demographics.
UTI, urinary tract infection.
The top 20 medication classes with correlating number of fills, percentages, and percentage point difference for the matched cohorts can be found in Table 3. These medications were found to be statistically significant with a percentage point difference of 1 or greater except for DPP4i. All other medications of interest were found to have less than 1 percentage point difference (located in Supplemental Appendix 4). The medications with the largest percentage point difference were opioids at 3.70, statins at 3.42, amoxicillin at 2.48, metformin at 2.45, and PPIs at 2.19. Other medications with percentage point differences of 1 or greater are included in Figure 1.
New prescription fills based on group.
ACEi, angiotensin-converting enzyme inhibitor; ARB, angiotensin II receptor blocker; CCB, calcium channel blocker; DPP4i, dipeptidyl-peptidase-4 inhibitor; GABA, gamma-aminobutyric acid; GLP1-RA, glucagon-like peptide 1 receptor agonist; PPI, proton pump inhibitor; SABA, short-acting beta agonist; SGLT2i, sodium-glucose transporter 2 inhibitor; SSRI, selective serotonin reuptake inhibitor; SU, sulfonylureas; UTI, urinary tract infection.
All medications were found to have a p-value of <0.001 and are considered statistically significant.

Medications with a greater than 1 percentage point difference.
Discussion
This large sample size and observational cohort allowed us to identify new medications filled prior to UTI events and compare the frequency with new medication fills for those without a UTI among patients with T2DM. Opioids had the largest difference in new initiations at a 3.70 percentage point difference, whereas SGLT2i were 19th on the list and had a percentage point difference of 1.14. This indicates that opioids had the highest likelihood of being newly filled by a patient 0–6 months prior to developing a UTI compared to patients who did not develop a UTI. This finding has been reported in one prior study identifying it in the top five medications prescribed prior to index UTI in individuals with DM, HF, or both. 42 This is an important finding, especially when found in a comparator group, given that opioids already lead to other complications such as overdose, addiction, and respiratory depression. One reason for this could be due to the potential immunosuppressive effects of opioids as reported in prior research related to decreased macrophage functionality, increased cellular apoptosis, decreased production of tumor necrosis factor-alpha, decreased natural killer cells, dendritic cells, T lymphocytes, and B lymphocytes.33–41 Another reason could be related to opioid induced constipation. Although no direct correlation has been identified linking this form of constipation to UTI incidence, it cannot be ruled out since constipation itself can increase the risk for UTI development through bladder or urethra dysfunction.46–48
Statins were the second largest difference in new initiations. This could be due to clinicians following the American Diabetes Association Standard of Care 2025 or the ACC/AHA Guidelines for prescribing statin therapy, which recommends starting statins in patients with diabetes aged 40–75 for primary prevention of ASCVD.49–51 Currently, there are no studies associating statins with increased incidence of UTIs. One thought is that many patients who are newly diagnosed with diabetes and are initiated on statins are uncontrolled, leading to an increased risk of UTIs based on elevated blood glucose. A limitation of this study is not having relative A1c data to assess severity of diabetes for patients prescribed statins in both cohorts.
Amoxicillin had the next highest percentage point difference. This finding could have been a result of the medication being prescribed prophylactically or at the time of UTI diagnosis and submitted as claim data prior to the ICD-10 code being submitted or due to a prior infection within the last 6 months. As mentioned in the background section, prior antibiotic use can increase the risk of UTI development.29–32 Like statins, metformin is another commonly prescribed medication for newly diagnosed diabetics. Metformin has also been used as a comparator arm in observational trials examining the incidence of UTIs compared to other diabetic agents, given its overall low incidence of UTI development and association with lower risk of UTI development.15,20,52,53 We suspect that individuals with newly prescribed metformin were likely at higher risk of UTI development based on uncontrolled blood glucose levels at baseline. Lastly with PPIs, recent studies have reported that use of PPIs is associated with extended-spectrum beta-lactamase producing Enterobacteriaceae (ESBL) UTIs and is deemed a risk factor.54–56 Mechanism for this occurring is thought to be through gastric acid suppression of the PPI allowing for increased survival of pathogens.57,58 This is important to note given that PPIs are available over the counter, over-prescribed by providers, and are continued past recommended duration of therapy.
SGLT2i ranked 19th based on percent difference out of all the medications of interest including most diabetic agents commonly prescribed. Although this result seems surprising based on the mechanism of SGTL2 inhibitors causing increased renal glucose excretion, it does align with similar findings in previous studies using claims databases that capture a robust population of patients.9–15 One thought could be that there is an ongoing risk of infection versus upon initiation or within the first 6 months of therapy. Another reason could be prescribing bias from providers avoiding the use of medication due to concerns of UTI in the setting of uncontrolled T2DM. Concern would be around the potential of excessive glucose excretion at the time of new diagnosis of T2DM or with elevated A1cs. Since SGLT2i have proven ASCVD and renal benefits in patients with and without T2DM, it may be appropriate to start considering these agents as first-line therapies in those patients who have risk factors for ASCVD and renal disease outweighing the risk or concern for UTI development.
Strengths to this study include the use of real-world data in the setting of a matched cohort involving a large sample size with high numbers of prescription and medical claims to identify small but impactful differences. There were several limitations to this study. One limitation was the inability to assess glycemic control, lab data, or duration of T2DM of the patients in this study, since uncontrolled diabetes increases the risk for developing UTIs. Also, based on the type of data available, it is unknown what other potential disease states the patients may have that could be confounding factors outside of the exclusion criteria, such as obesity, bladder dysfunction, and baseline glucosuria. Patients were not excluded if they had a prior UTI to try and capture more robust data. This could be viewed as a limitation since prior UTI history could place patients at higher risk for a recurrent episode. Another limitation includes the use of prescription fill data instead of other measures of adherence. Medicaid claims consisted of a low percentage of patients due to claims data only having managed Medicaid and not fee-for-service, which is the predominant Medicaid method across the United States. Selection bias around prescribing certain medications, either based on formulary requirements or prescriber preference, is another limitation. Some other drug classes may be associated with UTIs (i.e., anticholinergics or anticonvulsants) but were not included. The last limitation includes the use of reliance on appropriate coding from the institution and reliance on patients using insurance to obtain medications instead of paying out of pocket or obtaining samples.
Conclusion
This study adds to existing literature around the incidence of UTI development after filling certain medications. Opioids, statins, amoxicillin, metformin, and PPIs were in the top five, implying they were more likely to be newly filled compared to other medications within the first 6 months before developing a UTI. SGLT2i were not in the top 10 medications. Based on this, prescribing providers should be more aware of possible UTI development after prescribing opioids versus prescribing SGLT2i in patients with T2DM.
Supplemental Material
sj-docx-1-taw-10.1177_20420986251401515 – Supplemental material for Impact of recently initiated medications on the incidence of urinary tract infections in patients with type 2 diabetes: an observational case-control study
Supplemental material, sj-docx-1-taw-10.1177_20420986251401515 for Impact of recently initiated medications on the incidence of urinary tract infections in patients with type 2 diabetes: an observational case-control study by Joseph Ben Hill, Alexis Simons, Garth Wright and Kelly E. Anderson in Therapeutic Advances in Drug Safety
Supplemental Material
sj-docx-2-taw-10.1177_20420986251401515 – Supplemental material for Impact of recently initiated medications on the incidence of urinary tract infections in patients with type 2 diabetes: an observational case-control study
Supplemental material, sj-docx-2-taw-10.1177_20420986251401515 for Impact of recently initiated medications on the incidence of urinary tract infections in patients with type 2 diabetes: an observational case-control study by Joseph Ben Hill, Alexis Simons, Garth Wright and Kelly E. Anderson in Therapeutic Advances in Drug Safety
Footnotes
References
Supplementary Material
Please find the following supplemental material available below.
For Open Access articles published under a Creative Commons License, all supplemental material carries the same license as the article it is associated with.
For non-Open Access articles published, all supplemental material carries a non-exclusive license, and permission requests for re-use of supplemental material or any part of supplemental material shall be sent directly to the copyright owner as specified in the copyright notice associated with the article.
