Neuroinflammation is a common pathological feature and onset in multiple cognitive disorders, including postoperative cognitive dysfunction (POCD). Iron deposition was proved to participate in this process. But how iron mediates inflammation-induced cognitive deficits remains unknown. This study aimed to investigate the mechanism of iron through the neuroprotective effect of the iron chelator deferoxamine (DFO) in a mouse model of lipopolysaccharide (LPS)-induced cognitive impairment. Adult C57BL/6 mice were pretreated with 0.5 μg of DFO three days before intracerebroventricular microinjection of 2 μg of LPS. The mice showed memory deficits by showing decreased percentage of distance and the time within the platform-site quadrant, fewer platform-site crossings, and shortened swimming distance around the platform in the Morris water maze test, which were significantly mitigated by DFO pretreatment. Mechanistically, DFO prevented LPS-induced iron accumulation and modulated the imbalance of proteins expression related to iron metabolism, including elevated transferrin (TF) levels and reduced ferritin (Fth) caused by LPS. DFO attenuated the LPS-induced lipid peroxidation and oxidative stress, which is evidenced by the decrease of malondialdehyde (MDA) and lipid peroxidation (LPO) levels and the increase of superoxide dismutase (SOD) activity and glutathione (GSH) concentration. Moreover, DFO ameliorated ferroptosis-like mitochondrial damages in the hippocampus and also alleviated the expression of ferroptosis-related proteins in the hippocampus. Additionally, DFO attenuated microglial activation, alleviated LPS-induced inflammation, and reduced elevated levels of IL-6 and TNF-α in the hippocampus. Taken together, our findings suggested that DFO exerts neuroprotective effects by alleviating excessive iron participation in lipid peroxidation, reducing the occurrence of ferroptosis, inhibiting the vicious cycle between oxidative stress and inflammation, and ultimately ameliorating LPS-induced cognitive dysfunction, providing novel insights into the immunopathogenesis of inflammation-related cognitive dysfunction and future potential prevention options targeting iron.