Metazoan internal organs are assembled from polarized tubular epithelia that must set aside an apical membrane domain as a lumenal surface. In a global Caenorhabditis elegans tubulogenesis screen, interference with several distinct fatty-acid-biosynthetic enzymes transformed a contiguous central intestinal lumen into multiple ectopic lumens. We show that multiple-lumen formation is caused by apicobasal polarity conversion, and demonstrate that in situ modulation of lipid biosynthesis is sufficient to reversibly switch apical domain identities on growing membranes of single post-mitotic cells, shifting lumen positions. Follow-on targeted lipid-biosynthesis pathway screens and functional genetic assays were designed to identify a putative single causative lipid species. They demonstrate that fatty-acid biosynthesis affects polarity through sphingolipid synthesis, and reveal ceramide glucosyltransferases (CGTs) as end-point biosynthetic enzymes in this pathway. Our findings identify glycosphingolipids, CGT products and obligate membrane lipids, as critical determinants of in vivo polarity and indicate that they sort new components to the expanding apical membrane.