Inhibition of histone deacetylase (HDAC) may be a useful approach in the treatment of disorders characterized by cognitive dysfunction. Dexmedetomidine (DEX), an α2‐adrenoceptor (α2‐AR) agonist, has demonstrated neuroprotective effects. Here, we attempted to investigate the protective effects of DEX on postoperative cognitive dysfunction (POCD) involving HDAC2. Male C57BL/6 mice were selected to develop a POCD model, where HDAC2, HIF‐1α, and PFKFB3 expression was quantified. DEX was administered before POCD modeling. Then the cognitive function of POCD mice was evaluated with the open field and Y‐maze tests. Meanwhile, lipopolysaccharide (LPS) was employed to induce BV‐2 microglial cells to simulate the inflammatory response. The contents of TNF‐α, IL‐6, and IL‐10 were measured by enzyme‐linked immunosorbent assay (ELISA) in mouse serum and BV‐2 cell supernatant. Abundant expression of HDAC2, HIF‐1α, and PFKFB3 was confirmed in POCD mice (p < 0.05). Cognitive dysfunction in POCD mice could be alleviated following pharmacological inhibition of HDAC2 by FK228 (p < 0.05). Mechanistically, HDAC2 upregulated HIF‐1α and PFKFB3 and promoted the secretion of inflammatory factors in LPS‐exposed BV‐2 cells (p < 0.05). DEX attenuated neuroinflammation and the resulting cognitive dysfunction by decreasing HDAC2 expression and HIF‐1α‐dependent PFKFB3 upregulation in POCD mice (p < 0.05). In conclusion, DEX‐regulated HDAC2 may play an inhibitory role in mice with POCD through regulation of the HIF‐1α/PFKFB3 axis.