Developing efficient, stable, and low-cost novel electron-cocatalysts is crucial for photocatalytic hydrogen evolution reaction. Herein, amorphous NiP alloy particles were successfully modified onto g-C 3 N 4 to construct the Ni-P/ g-C 3 N 4 photocatalyst through a simple and green triethanolamine (TEOA)-mediated photodeposition method. It was found that the TEOA could serve as an excellent complexing agent to coordinate with Ni 2+ to form [Ni(TEOA)] 2+ complex, which can promote the rapid and effective deposition of amorphous NiP alloy on the g-C 3 N 4 surface. Photocatalytic tests suggest that the hydrogen-evolution performance of g-C 3 N 4 can be greatly promoted through integrating amorphous NiP alloy. Especially, the Ni-P/g-C 3 N 4 (5 wt%) exhibits the superior H 2-generation activity (118.2 μmol h −1 g −1), which is almost 35.8 times that of bare g-C 3 N 4. Furthermore, the amorphous NiP alloy cocatalyst can also serve as the general hydrogen-production cocatalyst to greatly enhance the photocatalytic performance of traditional semiconductor materials such as TiO 2 and CdS. Based on the present results, the mechanism of the amorphous NiP alloy as the high-efficiency electron transfer medium was proposed for the boosted H 2generation rate. The present facile route may broaden the horizons for the efficient development of highly active cocatalysts in photocatalytic field.