The effect of adding magnesium to lithium on lithium electrochemical behavior in 4molL−1 LiOH is studied using electrochemical techniques. The results show that the hydrogen evolution rate is decreased with increasing Mg content. Through theoretical analysis and X-ray (XRD) investigation, MgH2 and Mg(OH)2 are created on the surface film of lithium–magnesium alloys after discharge. The porosity of the lithium surface film is decreased by MgH2, Mg(OH)2 combined with LiOH and LiOH·H2O and the hydrogen evolution rate is decreased effectively. Magnesium addition to lithium reduces the extent of hydrogen evolution by alteration of the hydride–hydroxide layer also reduces the extent of anodic dissolution without a significant change in the system efficiency.