The ability of intracellular and extracellular Mg(2+) to block secretory K(+) currents through ROMK channels under physiologic conditions is incompletely understood. We expressed ROMK2 channels in Xenopus oocytes and measured unitary currents in the inside-out and cell-attached modes of the patch-clamp technique. With 110 mM K(+) on both sides of the membrane, 0.2 to 5 mM Mg(2+) on the cytoplasmic side reduced outward currents, but not inward currents, at V(m) > 0. With 11 or 1.1 mM extracellular K(+) ([K(+)](o)), ≥0.2 mM Mg(2+) blocked outward currents in the physiologic V(m) range (0 to -60 mV). With decreasing [K(+)](o), the apparent dissociation constant of the blocker decreased, but the voltage dependence of block did not significantly change. Whole-cell recordings from principal cells of rat cortical collecting ducts revealed similar inhibitory effects of intracellular Mg(2+). Mg(2+) added to the extracellular solution also reduced single-channel currents with an affinity that increased as [K(+)](o) decreased. In conclusion, physiologic concentrations of intracellular and extracellular Mg(2+) can influence secretory K(+) currents through ROMK channels. These effects could play a role in the modulation of K(+) transport under conditions of K(+) and/or Mg(2+) depletion.