Alloying is one of the powerful methods to exceed the intrinsic properties of pure metals; however, it is challenging to understand the exact alloying effect without altering other parameters, such as crystal structure. In this study, we chose iron and nickel phosphides as model catalysts for the hydrogen evolution reaction (HER) to elucidate the alloying effect of FexNi2-xP (x = 0.5, 1.0, and 1.5), which has the same P (6) over bar 2m crystal structure with different alloy compositions. The Fe0.5Ni1.5P catalyst recorded the optimal HER performances, including small overpotential (0.163 V at 50 mA cm(-2)), low Tafel slope (65 mV dec(-1)), and high exchange current density (0.37 mA cm(-2)), which were superior to pure Ni2P, Fe2P, and other FexNi2-xP catalysts in acidic media. The charge of phosphorus atoms in Fe0.5Ni1.5P was proven the most deficient one by X-ray photoelectron spectroscopy (XPS). The extended X-ray absorption fine structure (EXAFS) data supported that the small distortion degree of the metal-metal (M-M) bonds in the Fe0.5Ni1.5P significantly suppresses the metal to phosphorus (M-to-P) charge transfer and increases the electronic deficiency of phosphorus atoms. We also performed the density functional theory (DFT) calculation to support our charge trend of phosphorus and local distortion of M-to-P bonds. Our finding provided the observation of electron-deficient phosphorus sites modulated by the alloy composition of FexNi2-xP and showed how the degree of the M-M bond distortion correlates with HER properties in acidic media.