Magnesium is needed for the secretion of PTH by the parathyroid glands and its depletion or excess may cause hypoparathyroidism and subsequent hypocalcemia. This evidence concerns the gene PTH and hypoparathyroidism.