Objectives: To evaluate the association between the long-term use of bisphosphonates and the risk of hip fracture compared to never use among women aged 65 years or older. Design: Case-control study nested in a cohort. Setting: General practice research database operated by the Spanish Medicines Agency. Participants: Cases of hip fracture were defined as women aged 65 years or older with a validated first diagnosis of hip fracture between 2005 and 2008. Five controls free of hip fracture were matched on age and calendar-year with each case. Interventions: Information on bisphosphonate use, hip fractures, comedication and comorbidities was collected. Primary outcomes: Hip fracture risk comparing bisphosphonate users versus never users. Secondary outcomes: Hip fracture risk comparing bisphosphonate users versus never users by individual drugs. Results: The study included 2009 incident hip fractures and 10 045 matched controls. Hip-fracture risk did not differ between bisphosphonate users and never users, adjusted OR=1.09 (95% CI 0.94 to 1.27). No association was observed between hip fracture risk and cumulative duration of bisphosphonate treatment. However, when treatment duration is analysed as time since first prescription, hip fracture risks of the different subgroups compared to never users obtained were as follows: <1 year, OR 0.85 (95% CI 0.60 to 1.21); 1 to <3 years, OR 1.02 (95% CI 0.82 to 1.26); ≥3 years, OR 1.32 (95% CI 1.05 to 1.65) (p for trend=0.03). Conclusions: Ever use of oral bisphosphonates was not associated with a decreased risk of hip fracture in women aged 65 or older as compared to never use. No association was observed between hip fracture risk and cumulative duration of bisphosphonate treatment. However, when treatment duration is analysed as time since first prescription, a statistically significant increased risk for hip fracture was observed in patients exposed to bisphosphonates over 3 years.