Loop diuretics (LD) may affect bone health by inhibiting renal calcium reuptake. However, whether vitamin D status and dietary calcium intake modify the association between LD and bone outcome is unclear. Therefore, this study aimed to evaluate whether vitamin D level or calcium intake modify the association between LD and various indices of bone health including bone mineral density (BMD) and Trabecular Bone Score (TBS). From The Rotterdam Study, a prospective population-based cohort study, we used data from 6990 participants aged > 45 year with a DXA scan (2002–2008), 6908 participants with femoral neck (FN)-BMD, 6677 participants with lumbar spine (LS)-BMD and 6476 participants with LS-TBS measurements. Use of LD was available from pharmacy dispensing records. Vitamin D (25(OH)D) level was measured in serum, and dietary calcium intake was measured with a validated food frequency questionnaire. Almost eight percent of the participants used LD. The association between LD (past-users compared to never-users) and LS-TBS was significantly different by 25(OH)D concentrations (P for interaction = 0.04). A significantly lower LS-TBS among LD past-users was observed for 25(OH)D ≥ 50 nmol/l compared to ≤ 20 and 20–50 nmol/l (β = − 0.036, 95% CI − 0.060; − 0.013 vs. β = − 0.012, 95% CI − 0.036; 0.013 and β = − 0.031, 95% CI − 0.096; 0.034, respectively). However, no other significant effect modification by 25(OH)D and dietary calcium intake was found in the associations between LD use and bone health outcomes (P-interaction > 0.13). This study suggests that the association between LD use and indices of bone health is not consistently modified by vitamin D or dietary calcium intake.