The relationship between the integrity of white matter tracts and cortical function in the human brain remains poorly understood. We investigate reversible white matter injury, in this case patients with compression of the optic chiasm by pituitary gland tumors, to study the structural and functional changes that attend spontaneous recovery of cortical function and visual abilities after surgical removal of the tumor and subsequent decompression of the nerves. We show that compression of the optic chiasm led to demyelination of the optic tracts, which reversed as quickly as 4 weeks after nerve decompression. Furthermore, variability across patients in the severity of demyelination in the optic tracts predicted visual ability and functional activity in early cortical visual areas. Preoperative measurements of myelination in the optic tracts predicted the magnitude of visual recovery after surgery. These data indicate that rapid regeneration of myelin in the human brain is a component of the normalization of cortical activity, and ultimately the recovery of sensory and cognitive function, after nerve decompression. More generally, our findings demonstrate the use of diffusion tensor imaging as an in vivo measure of myelination in the human brain.