Abstract The electronic structure, elasticity, and magnetic properties of the Mn2XIn (X = Fe, Co) full-Heusler compounds are comprehensively investigated via first-principles calculations. The calculated elastic constants indicate that both Mn2FeIn and Mn2CoIn possess ductility. At the optimal lattice constants, the magnetic moments are found to be 1.40 μB/f.u for Mn2FeIn and 1.69 μB/f.u for Mn2CoIn. Under the biaxial strain ranging from -2% to 5%, Mn2FeIn demonstrates a remarkable variation in the spin polarization, spanning from -2% to 74%, positioning it as a promising candidate for applications in spintronic devices. Analysis of the electronic structure reveals that the change in spin polarization under strain is due to the shift of the spin-down states at the Fermi surface. Additionally, under biaxial strain, the magnetic anisotropy of Mn2FeIn undergoes a transition of easy-axis direction. Utilizing second-order perturbation theory and electronic structure analysis, the variation in magnetic anisotropy with strain can be attributed to changes of d-orbital states near the Fermi surface.