Multi-spanning membrane protein loops are directed alternately into the cytosol or ER lumen during cotranslational integration. Nascent chain exposure is switched after a newly synthesized transmembrane segment (TMS) enters the ribosomal tunnel. FRET measurements revealed that each TMS is initially extended, but folds into a compact conformation after moving 6-7 residues from the peptidyltransferase center, irrespective of loop size. The ribosome-induced folding of each TMS coincided with its photocrosslinking to ribosomal protein L17 and an inversion of compartmental exposure. This correlation indicates that successive TMSs fold and bind at a specific ribosomal tunnel site that includes L17, thereby triggering structural rearrangements of multiple components in and on both sides of the ER membrane, most likely via TMS-dependent L17 and/or rRNA conformational changes transmitted to the surface. Thus, cyclical changes at the membrane during integration are initiated by TMS folding, even though nascent chain conformation and location vary dynamically in the ribosome tunnel. Nascent chains therefore control their own trafficking.