Real-world evidence assessing dipeptidyl peptidase-4 inhibitors (DPP4i)'s risk of inflammatory bowel disease (IBD) is conflicting. One study modelling DPP4i as a time varying exposure (TVE) observed a harmful effect in a UK population, while an active-comparator new-user (ACNU) study observed a null effect in a US population. To assess the impact of study design in estimating treatment effect, we implemented both designs in the UK Clinical Practice Research Datalink population from 2007-2022. We conducted three ACNU analyses: DPP4i vs. sulfonylureas (SU) (43,204 vs 86,411), DPP4i vs. thiazolidinediones (TZD) (67,288 vs 22,474), and DPP4i vs. sodium-glucose transport protein 2 inhibitors (SGLT2i) (54,253 vs 30,993). The propensity score adjusted hazard ratios (aHRs) for DPP4i were 1.12 (95% CI 0.83-1.50) vs SU, 1.15 (0.66-2.01) vs TZD, and 1.43 (0.83-2.48) vs SGLT2i, over a median follow-up of 2.2 to 6.1 years. In TVE analyses, patients who switched from the comparator to DPP4i were censored at switching and accrued person-time on DPP4i thereafter. We observed similar or higher aHRs for DPP4i vs SU 1.06 (0.80-1.41), TZD 1.76 (0.84-3.78), and SGLT2i 1.62 (0.91-2.90) . Our findings suggest DPP4i does not increase IBD risk and emphasize the crucial role of study design in assessing treatment effect.