Axonal degeneration is responsible for disease progression and accumulation of disability in many neurodegenerative conditions. The axonal degenerative process can generate a metastable pool of damaged axons that remain structurally and functionally viable but fated to degenerate in the absence of external intervention. SARM1, an NADase that depletes axonal energy stores upon activation, is the central driver of an evolutionarily conserved program of axonal degeneration. We identify a potent and selective small molecule isoquinoline inhibitor of SARM1 NADase that recapitulates the SARM1-/- phenotype and protects axons from degeneration induced by axotomy or mitochondrial dysfunction. SARM1 inhibition post-mitochondrial injury with rotenone allows recovery and rescues axons that already entered the metastable state. We conclude that SARM1 inhibition with small molecules has the potential to treat axonopathies of the central and peripheral nervous systems by preventing axonal degeneration and by allowing functional recovery of a metastable pool of damaged, but viable, axons.