Sevoflurane induces developmental neurotoxicity in mice; however, the underlying mechanisms remain unclear. Triggering receptor expressed on myeloid cells 2 (TREM2) is essential for microglia-mediated synaptic refinement during the early stages of brain development. We explored the effects of TREM2 on dendritic spine pruning during sevoflurane-induced developmental neurotoxicity in mice. Mice were anaesthetized with sevoflurane on postnatal days 6, 8, and 10. Behavioral performance was assessed using the open field test and Morris water maze test. Genetic knockdown of TREM2 and overexpression of TREM2 by stereotaxic injection were used for mechanistic experiments. Western blotting, immunofluorescence, electron microscopy, three-dimensional reconstruction, Golgi staining, and whole-cell patch-clamp recordings were performed. Sevoflurane exposures upregulated the protein expression of TREM2, increased microglia-mediated pruning of dendritic spines, and reduced synaptic multiplicity and excitability of CA1 neurons. TREM2 genetic knockdown significantly decreased dendritic spine pruning, and partially aggravated neuronal morphological abnormalities and cognitive impairments in sevoflurane-treated mice. In contrast, TREM2 overexpression enhanced microglia-mediated pruning of dendritic spines and rescued neuronal morphological abnormalities and cognitive dysfunction. TREM2 exerts a protective role against neurocognitive impairments in mice after neonatal exposures to sevoflurane by enhancing microglia-mediated pruning of dendritic spines in CA1 neurons. This provides a potential therapeutic target in the prevention of sevoflurane-induced developmental neurotoxicity.