There is a paucity of previous related studies exploring hexagonal MgZn2 in high-pressure environments. This study systematically analyzes the mechanical behavior of MgZn2 hexagonal alloys under high-pressure conditions using first principle calculations, bridging the gap in research in this area in the field. The results reveal that, with increasing pressure, the crystallite spacing (a/a0,c/c0) and ratio of volumes (V/V0) decrease significantly, indicating the structural condensation of the material under high pressure. Elastic constant analysis showed a notable enhancement in all constants, except for C13. Among them, C11 increased from 87.399 GPa to 311.45 GPa, and C33 increased from 135.279 GPa to 341.739 GPa, showing a faster growth rate, suggesting improved tensile strength in the material along the tensile direction. Mechanical stability assessments confirmed that the alloy remains stable over the 0 to 30 GPa pressure range. Further material characterization indicated that Poisson’s ratio remained above 0.26 at pressures from 0 to 30 GPa, suggesting excellent ductility and agreeing with the ratio of the shear modulus to the bulk modulus. As the pressure increases, both the hardness and sound velocity of MgZn2 increase, while the degree of anisotropy decreases. The present work gives important insights on the mechanical behavior of MgZn2 under high pressure, contributing to its application and property optimization.