Research question: Does the fertility-enhancing effect of tubal flushing during hysterosalpingography (HSG) with oil-based contrast change over time? Design: This was a secondary analysis of the H2Oil (long-term follow-up) study, a multicentre randomized controlled trial evaluating the effectiveness of oil-based and water-based contrast during HSG. The main outcome was ongoing pregnancy. Cox proportional hazards models for time to ongoing pregnancy were fitted over 3 years of follow-up. Results: Data on 1107 couples were available; 550 couples had oil-based contrast and 557 water-based contrast at HSG. Ongoing pregnancy rates after 3 years were 77% and 71%, respectively. Median follow-up was 9–10 months (5th—95th percentile: <1 to 36). The hazard ratio for ongoing pregnancy for oil versus water over 3 years of follow-up was 1.26 (95% confidence interval [CI] 1.10–1.45). The scaled Schoenfeld residual plots showed a decrease in hazard ratio that was linear with log-transformed time. After including an interaction with log-transformed time, the hazard ratio immediately after HSG was 1.71 (95% CI 1.27–2.31) and reduced to no effect (hazard ratio of 1) at approximately 2 years. There was no evidence for a change in hazard ratio over time in a subgroup of women who experienced pain during HSG. Conclusions: The hazard ratio for ongoing pregnancy of oil-based versus water-based contrast was 1.71 immediately after HSG, gradually decreasing and plateauing towards a hazard ratio of 1 (indicating no effect) after approximately 2 years. This supports the hypothesis that oil-based contrast might dislodge debris or mucus plugs from the Fallopian tubes, but this has yet to be definitively proved.