Mg and Ca transport was studied in the superficial proximal tubule, loop of Henle and superficial distal tubule of the rat by in vivo microperfusion. MgCl was used to vary plasma and perfusate Mg concentration. Perfusion with Mg-free Ringer solution resulted in little Mg entry into the tubule lumen in either normomagnesemic or hypermagnesemic rats. Mg concentration increased with H2O along the perfused proximal tubule whether markedly above or below plasma concentrations. Absolute proximal Mg reabsorption increased with perfusate concentration; fractional Mg and Ca reabsorption decreased in proportion to net Na reabsorption with elevated extracellular Mg. Mg absorption increased in the loop of Henle proportional to luminal Mg concentration. Na and Ca reabsorption was not affected. Acute elevation of plasma Mg significantly depressed absolute Mg reabsorption to a greater degree than Ca whereas Na was unchanged. The effects of extracellular Mg on loop reabsorption were reflected in the final urine. Reabsorption of Na, Ca and Mg in the perfused distal tubule was concentration-dependent and not altered by luminal or extracellular Mg concentration.