TiAl alloy has attracted significant attention as a candidate material with high melting temperature, low density, relatively high hardness and excellent corrosion resistance, good oxidation and creep resistance at high temperatures. The inherent brittleness at low temperatures is by far the greatest hurdle that prevents it from being widely used in industries. Doping has long been considered as an effective way to improve the performance of alloy. The properties of TiAl alloy are highly dependent on the third alloying element. Although the mechanical properties of TiAl alloy are improved to a certain extent by adjusting the composition, to date the physical mechanism has been still unclear. In this paper, from the microscopic electronic structure the influence of metal element X (X represents V, Nb, Ta, Cr, Mo and W) doping on the mechanical properties of TiAl alloy is studied by first-principle method. The first-principle calculations presented here are based on electronic density-functional theory framework. The ultrasoft pseudopotentials and a plane-wave basis set with a cut-off energy of 350.00 eV are used. The generalized gradient approximation refined by Perdew and Zunger is employed for determining the exchange-correlation energy. Brillouin zone is set to be within 888 k point mesh generated by the Monkhorst-Pack scheme. The self-consistent convergence of total energy is at 5.010-7 eV/atom. The supercell (222), (221) and (121) are selected as a computational model. According to the calculated structural parameters of the doped systems, we find that the lattice constant ratio c/a decreases with the increase of doping ratio, correspondingly the anisotropy of crystal reduces. The interactions between Ti and Al atoms are enhanced. Under the same pressure, the influences of doping concentration and type of doping element on volume are different. According to the obtained elastic constants, bulk moduli and shear moduli of doping systems, we find that with a doping concentration of 6.25%, Cr, Mo and W doping can improve the toughness of TiAl alloy more than V, Nb and Ta doping. For a doping concentration of 12.5%, the toughening effect of Mo is the strongest in all the six doping elements. The strong s-s, p-p and d-d electron interactions exist between the Ti and Mo atom, which is verified by the results of partial electron density of state and charge density. The strong interaction caused by doping restricts effectively the migration of Ti and Al atom. It is beneficial to enhance the stability and strength of the TiAl alloy. In summary, starting from the microscopic electronic structure we find that doping can effectively reduce the anisotropy of TiAl alloy, enhance the interaction between Ti and Al atoms, weaken covalent bond energy, enhance metal bond energy and then promote the plastic deformation of TiAl alloy. The results can provide theoretical support for improving the performances of TiAl based alloys.