As oligodendrocytes wrap axons of the central nervous system (CNS) with insulating myelin sheaths, sodium channels that are initially continuously distributed along axons become segregated into regularly spaced gaps in the myelin called nodes of Ranvier. It is not known whether the regular spacing of nodes results from regularly spaced glial contacts or is instead intrinsically specified by the axonal cytoskeleton. Contact with Schwann cells induces clustering of sodium channels along the axons of peripheral neurons in vitro and in vivo. Similarly, it has been suggested that astrocyte contact induces clustering of sodium channels along CNS axons. Here we show that oligodendrocytes are necessary for clustering of sodium channels in vitro and in vivo. The induction, but not the maintenance, of sodium-channel clustering along the axons of highly purified rat retinal ganglion cells in culture depends on a protein secreted by oligodendrocytes. Surprisingly, the oligodendrocyte-induced clusters are regularly spaced at the predicted interval in the absence of glial-axonal contact. Mutant rats that are deficient in oligodendrocytes develop few axonal sodium channel clusters in vivo. These results demonstrate a crucial role for oligodendrocytes in inducing clustering of sodium channels.