Objective: We aimed to explore the correlations between and possible mechanisms of common environmental endocrine disruptors, phthalates, and ovarian dysfunction in endometriosis. Methods: Subjects were included in the case group (n = 107) who were diagnosed with endometriosis by postoperative pathology in Fujian Maternal and Child Hospital from February 2018 to February 2021, and the women who were excluded from endometriosis by surgery were as the control group (n = 70). The demographic information of the subjects were evaluated by questionnaire, and the clinical characteristics were evaluated by medical records and 3-year follow-up results. Gas chromatography‒mass spectrometry was used to quantify 10 metabolites of phthalates, including dimethyl ortho-phthalate (DMP), mono-n-methyl phthalate (MMP), dioctyl ortho-phthalate (DEP), mono-ethyl phthalate (MEP), di-n-butyl ortho-phthalate (DBP), mono-butyl phthalate (MBP), benzylbutyl phthalate (BBzP), mono-benzyl; phthalate (MBzP), diethylhexyl phthalate (DEHP) and mono-ethylhexyl phthalate (MEHP), in the urine samples of the subjects. Furthermore, a total of 54 SD rats were exposed to DEHP 0, 5, 50, 100, 250, 500, 1,000, 2000, and 3,000mg/kg/day for 2weeks. The SD rats' body weight, oestrus cycle changes, and serum anti-mullerian hormone (AMH) levels were evaluated. After sacrifice, the mass index of the rat uterus and bilateral ovaries were calculated. Finally, bioinformatics analysis of rat ovarian tissues was performed to explore the possible mechanism. SPSS 24.0 (IBM, United States) was used for data analysis. p-value <0.05 was considered statistically significant. Results: The human urinary levels of DMP (p < 0.001), MMP (p = 0.001), DEP (p = 0.003), MEP (p = 0.002), DBP (p = 0.041), MBP (p < 0.001), BBzP (p = 0.009), DEHP (p < 0.001), and MEHP (p < 0.001) were significantly higher in women with endometriosis than in controls. Notably, DEHP was a significant risk factor for endometriosis (OR: 11.0, 95% CI: 5.4-22.6). The area under the ROC curve increased when multiple phthalates were diagnosed jointly, reaching 0.974 as the highest value, which was helpful for the diagnosis of endometriosis. In vivo experiments showed that after DEHP exposure in rats, the mass index of the ovary and uterus decreased in a dose-dependent manner; the oestrus cycle of SD rats was irregularly prolonged and disordered; and the serum AMH level was negatively correlated with the DEHP exposure dose (Rho = -0.8, p < 0.001). Bioinformatics analysis of rat ovarian tissues showed that seven genes involved in the steroid biosynthesis pathway were upregulated and may play a negative role in ovarian function. Conclusion: Exposure to phthalates, especially DEHP, is associated with the occurrence of endometriosis and affects women's reproductive prognosis and ovarian function. The steroid biosynthesis pathway may be related to ovarian dysfunction. The detection of phthalate in urine may become a new biological target for the diagnosis of endometriosis.