Our results show that LS exhibited a preventive effect against the postpartum cognitive impairment than LO, which was associated with modifying the brain fatty acid composition and ameliorating brain neuroinflammation, repairing gut microbiota, and upregulating the expression of the SCFA/ERK(1/2)/CREB/BDNF pathway. Here, BDNF is linked to Cognitive impairment.