The study aimed to investigate the efficacy of Danggui Buxue Decoction (DBD) in treating primary dysmenorrhea (PD) and uncover its mechanisms, thereby validating its traditional use. Using ultra-high performance liquid chromatography-quadrupole time-of-flight mass spectrometry (UPLC-Q-TOF/MS), 38 compounds in DBD were identified. PD model rats were established via cold stimulation, estradiol benzoate, and oxytocin injections. DBD treatment improved behavioral parameters, reduced writhing response, and alleviated histopathological changes in uterus and ovary. Biochemical markers (PGE2, SOD and MDA, among others) were assessed using ELISA, and Western blot was employed to analyze protein levels in rat uteri. Results showed that DBD modulated these proteins, indicating its protective effects. The study provides scientific evidence for DBD''s role in nourishing "qi" or enriching "blood" during PD treatment by affecting the MEK1/2/ERK1/2/NF-kappa B signaling pathway, thus reducing oxidative stress and proinflammatory factors in PD rats.