BackgroundOvarian cancer is one of the most lethal cancers and women with type 2 diabetes (T2D) have even poorer survival from it. We assessed the prognosis of ovarian cancer in women with type 2 diabetes treated with metformin, other forms of antidiabetic medication, or statins.MethodsStudy cohort consisted of women with T2D diagnosed with ovarian cancer in Finland 1998–2011. They were identified from a nationwide diabetes database (FinDM), being linked to several national registers. Patients were grouped according to their medication in the three years preceding ovarian cancer diagnosis. The Aalen–Johansen estimator was used to describe cumulative mortality from ovarian cancer and from other causes in different medication groups. Mortality rates were analysed by Cox models, and adjusted hazard ratios (HR) with 95% confidence intervals (95% CIs) were estimated in relation to the use of different forms of medication. Main outcome measures were death from ovarian cancer and death from other causes.ResultsDuring the accrual period 421 newly diagnosed ovarian cancers were identified in the FinDM database. No evidence was found for any differences in mortality from ovarian cancer or other causes between different antidiabetic medication groups. Pre-diagnostic use of statins was observed to be associated with decreased mortality from ovarian cancer compared with no such use (HR 0.72, 95% CI 0.56–0.93).ConclusionsOur findings are inconclusive as regards the association between metformin and ovarian cancer survival. However, some evidence was found for improved prognosis of ovarian cancer with pre-diagnostic statin use, requiring cautious interpretation, though.Electronic supplementary materialThe online version of this article (10.1186/s12885-018-4676-z) contains supplementary material, which is available to authorized users.