The issue of magnesia corrosion of grouting materials in oil and gas wells is very relevant in the construction of oil and gas wells since magnesia salts can lead to the destruction of Portland cement-based cement stone within few months. When fastening powerful intervals of salt deposits represented by magnesium salts, the use of magnesia cements is effective. However, individual layers and interlayers containing dissolved magnesium salts are not individually cemented, but overlap over the entire interval of the open hole with cement Portland cement, which can be destroyed due to magnesia corrosion. The main aim of the paper is to analyze the corrosion of Portland cement stone in aggressive environments of magnesia. As the quantitative indicators characterizing the degree of stone damage, the thickness of the damaged layer and the stone resistance coefficient are taken, characterized by the ratio of the compressive strength or bending strength of stone samples after being in an aggressive environment to the strength of control samples at the same hardening time. The corrosion resistance of cement stone was assessed after 8 weeks in an aggressive magnesia environment. Also, the role of MgCl2 concentration on the mechanism of corrosion damage to cement stone was studied. The use of reducing the water-cement ratio and adding palygorskite clay to reduce the porosity of cement stone and reduce the rate of corrosion damage is proposed. The kinetics and the main factors affecting the corrosion process were considered, an X-ray diffraction analysis of corrosion products and unaffected cement stone was carried out.