Magnesium deficiency was studied retrospectively in human infants and prospectively in experimental animals in order to evaluate its possible role in the pathogenesis of problems chiefly affecting premature human neonates of suboptimal economic status, who are at high risk for Mg deficiency. The problems include the sudden infant death syndrome (SIDS) and idiopathic respiratory distress syndrome (RDS). The near-miss for SIDS (near-SIDS) was studied from a group of 139 MG-unsupplemented premature neonates who had idiopathic apnea neonatorum who were readmitted with apnea at 70 plus-minus 6 days of age, and from 20 infants (19 term, 1 premature) who suddenly developed apnea for the first time at 48 plus-minus 12 days of age (apnea of late onset). The sickest infants of both groups exhibited similar clinical and laboratory findings of a metabolic crisis, with acidosis. Mg supplementation was associated with fewer subsequent readmissions for apnea. A hypothesis concerning the possible role of Mg deficiency in SIDS is proposed. During a very short span of time, the weanling rat with acute Mg deficiency is extremely sensitive to minimal external stimuli and may suddenly develop a near-fatal or fatal shock episode. Lungs show findings of shock. Morphometric analysis and electron microscopy revealed changes compatible with RDS: gaps between endothelial cells, hemorrhage, and edema, and components of the hyaline membranes in the alveolar sacs and ducts, with early deposition of eosinophilic material. Such findings were not found in Mg-sufficient rats challenged with strychnine seizures. Both Mg-deficient rats with audiogenic seizures and Mg-sufficient rats with strychnine seizures showed similar levels of plasma corticosterone, ruling out the possibility of suboptimal protection from glucocorticoids in Mg deficiency shock.