5-hydroxymethylfurfural (5-HMF) has been shown to exert neuroprotective effects in a global cerebral ischemia mouse model in our previous study, where it demonstrated antioxidant and anti-inflammatory properties. However, studies on its antidepressant mechanisms remain scarce. Since oxidative stress and neuroinflammation are closely associated with depression, this study investigated the antidepressant effects of 5-HMF, focusing on its potential inhibition of oxidative stress via the Nrf2 pathway and its role in microglial M1 polarization-mediated neuroinflammation. An acute depression mouse model induced by intraperitoneal injection of lipopolysaccharide (LPS) was utilized. Mice received 5-HMF (12 mg/kg) or an equal volume of vehicle via intraperitoneal injection 30 min prior to and 5 min after LPS administration. At 24 h post-modeling, behavioral tests (sucrose preference, forced swim, and open field tests) were conducted to evaluate the antidepressant effect of 5-HMF. Histological damage in the hypothalamus was assessed using Nissl staining and terminal deoxynucleotidyl transferase-mediated dUTP nick-end labeling (TUNEL) staining. Immunofluorescence was performed to evaluate M1 polarization of hypothalamic microglia. Oxidative stress damage was assessed by measuring malondialdehyde (MDA), carbonyl groups, and 8-hydroxy-2′-deoxyguanosine (8-OHdG) levels. Nrf2 DNA-binding activity was examined using an ELISA-based assay. The expression of inflammatory cytokines, Nrf2, and downstream antioxidant proteins was analyzed by ELISA kits and Western blotting. 5-HMF significantly alleviated LPS-induced depression-like behaviors, reduced hypothalamic neuronal damage, decreased oxidative stress, and inhibited microglial M1 polarization. It also regulated the expression of inflammatory cytokines (IL-1β, IL-6, TNF-α, IL-4, and IL-10) and activated the Nrf2 signaling pathway, enhancing nuclear translocation efficiency. Notably, these effects were significantly attenuated by the Nrf2 inhibitor brusatol. In conclusion, 5-HMF exerts neuroprotective effects by modulating Nrf2-mediated oxidative stress responses and suppressing microglial M1 polarization-driven neuroinflammation. These findings suggest that 5-HMF may provide therapeutic potential for alleviating depression symptoms induced by acute inflammation.