A new, ion-radical mechanism of enzymatic ATP synthesis was recently discovered by using magnesium isotopes. It functions at a high concentration of MgCl2 and includes electron transfer from the Mg(H2O)m2+(ADP3−) complex (m = 0−4) to the Mg(H2O)n2+ complex as a primary reaction of ATP synthesis in catalytic sites of ATP synthase and kinases. Here, the structures and electron transfer reaction energies of magnesium complexes related to ATP synthesis are calculated in terms of DFT. ADP is modeled by pyrophosphate anions, protonated (HP2O7H2−, HP2O7CH32−) and deprotonated (HP2O73−, CH3P2O73−). The reaction generates an ion-radical pair, composed of Mg(H2O)n+ ion and pyrophosphate anion-radical coordinated to Mg2+ ion. The addition of the latter to the substrate P═O bond results in ATP formation. Populations of the singlet and triplet states and singlet−triplet spin conversion in the pair are controlled by hyperfine coupling of unpaired electrons with magnetic 25Mg and 31P nuclei and by Zeeman interaction. Due to these two interactions, the yield of ATP is a function of nuclear magnetic moment and magnetic field; both of these effects were experimentally detected. Electron transfer reaction does not depend on m but strongly depends on n. It is exoergic and energy allowed at 0 ≤ n ≪ ∞ for the deprotonated pyrophosphate anions and at 0 ≤ n < 4 for the protonated ones; for other values of n, the reaction is energy deficient and forbidden. The boundary between exoergic and endoergic regimes corresponds to the trigger magnitude n* (n* = 4 for protonated anions and 6 < n* ≪ ∞ for deprotonated ones). These results explain why ATP synthesis occurs only in special devices, molecular enzymatic machines, but not in water (n = ∞). Biomedical consequences of the ion-radical enzymatic ATP synthesis are also discussed.