Peripheral glia help ensure that motor and sensory axons are bathed in the appropriate ionic and biochemical environment. In Drosophila, peripheral glia help shield these axons against the high K+ concentration of the hemolymph, which would largely abolish their excitability. Here, we describe the molecular genetic analysis of gliotactin, a novel transmembrane protein that is transiently expressed on peripheral glia and that is required for the formation of the peripheral blood-nerve barrier. In gliotactin mutant embryos, the peripheral glia develop normally in many respects, except that ultrastructurally and physiologically they do not form a complete blood-nerve barrier. As a result, peripheral motor axons are exposed to the high K+ hemolymph, action potentials fail to propagate, and the embryos are nearly paralyzed.