In the peripheral nervous system (PNS), damaged axons regenerate successfully, whereas axons in the CNS fail to regrow. In neurons of the dorsal root ganglia (DRG), which extend branches to both the PNS and CNS, only a PNS lesion but not a CNS lesion induces axonal growth. How this differential growth response is regulated in vivo is only incompletely understood. Here, we combine in vivo time-lapse fluorescence microscopy with genetic manipulations in mice to reveal how the transcription factor STAT3 regulates axonal regeneration. We show that selective deletion of STAT3 in DRG neurons of STAT3-floxed mice impairs regeneration of peripheral DRG branches after a nerve cut. Further, overexpression of STAT3 induced by viral gene transfer increases outgrowth and collateral sprouting of central DRG branches after a dorsal column lesion by more than 400%. Notably, repetitive in vivo imaging of individual fluorescently labeled PNS and CNS axons reveals that STAT3 selectively regulates initiation but not later perpetuation of axonal growth. With STAT3, we thus identify a phase-specific regulator of axonal outgrowth. Activating STAT3 might provide an opportunity to "jumpstart" regeneration, and thus prime axons in the injured spinal cord for application of complementary therapies that improve axonal elongation.