Clinical and animal studies have shown that acupuncture may benefit controlling neuropathic pain. However, the underlying molecular mechanisms are poorly understood. In a well-established mouse unilateral tibial nerve injury (TNI) model, we confirmed the efficacy of electroacupuncture (EA) in reducing mechanical allodynia and measured methylation and hydroxy-methylation levels in the primary somatosensory cortex (S1) and anterior cingulate cortex (ACC), two cortical regions critically involved in pain processing. TNI resulted in increased DNA methylation of both the contra- and ipsilateral S1, while EA only reduced contralateral S1 methylation. RNA sequencing of the S1 and ACC identified differentially expressed genes related to energy metabolism, inflammation, synapse function, and neural plasticity and repair. One week of daily EA decreased or increased the majority of up- or downregulated genes, respectively, in both cortical regions. Validations of two greatly regulated genes with immunofluorescent staining revealed an increased expression of gephyrin in the ipsilateral S1 after TNI was decreased by EA; while TNI-induced increases in Tomm20, a biomarker of mitochondria, in the contralateral ACC were further enhanced after EA. We concluded that neuropathic pain is associated with differential epigenetic regulations of gene expression in the ACC and S1 and that the analgesic effect of EA may involve regulating cortical gene expression.