Manipulating gene expression in vivo specifically in neurons with precise spatiotemporal control is important to study the function of genes or pathways in the nervous system. Although various transgenic approaches or virus-mediated transfection methods are available, they are time consuming and/or lack precise temporal control. Here we introduce an efficient electroporation approach to transfect adult dorsal root ganglion (DRG) neurons in vivo that enables manipulation of gene expression in an acute and precise manner. We have applied this method to manipulate gene expression in three widely used in vivo models of axon injury and regeneration, including dorsal column transection, dorsal root rhizotomy and peripheral axotomy. By electroporating DRGs with small interfering RNAs against c-jun to specifically deplete c-Jun in adult neurons, we provide evidence for the role of c-Jun in regulation of in vivo axon regeneration. This method will serve as a powerful tool to genetically dissect axon regeneration in vivo.