The interfacial perpendicular magnetic anisotropy (PMA) observed at ferromagnet/oxide interfaces presents great promise for energy-efficient spintronic technologies. The epitaxial strain induced by the lattice mismatch between films and substrates serves as an effective strategy for the tuning of the material properties. However, the current understanding of the strain effects on interfacial PMA remains insufficient. Here, we present an extensive study of the biaxial strain effects on the interfacial magnetism and interfacial magnetic anisotropy constant (Ki) in a slab-based Fe/MgO heterostructure using first-principles density functional theory calculations. Our results reveal a strong correlation between the spin moment of interfacial Fe atoms and the Fe-O bond length in both unstrained and strained systems. The overall Ki, which includes contributions from both the Fe/MgO interface and the Fe surface, increases as the compressive strain increases. This is consistent with recent experimental findings that show that the PMA energy increases when the in-plane lattice constant of Fe decreases. In contrast, the overall Ki initially decreases with a small tensile strain of less than 0.4% and shows an increasing trend as the tensile strain increases from 0.4% to 2%. However, beyond 2%, the overall Ki decreases again. These changes in Ki can be explained by the strain-induced variations of Fe 3d orbitals near the Fermi energy. This study provides a comprehensive understanding of the strain effects on magnetic anisotropy in Fe-based heterostructures, offering insights for the further optimization of interfacial magnetic properties.