Codeposition mechanism of phosphorus with nickel on an Ni Ag alloy electrode has been investigated by means of in situ surface enhanced Raman spectroscopy(SERS) and electrochemical method to obtain new information about the phosphorus incorporation mechanism during electrodeposition of Ni P alloys.The intermediate,Ni(PH3)n,in the electrodeposition of Ni P alloy was detected with in situ surface Raman spectroscopy for the first time. The experimental results showed that in the solution without NiSO4,hypophosphite was reduced only to Ni phosphine compound,while in the case where NiSO4 coexisted in the solution,the Ni phosphine compound,as an intermediate,was oxidized by Ni2+to elemental phosphorus in alloys with nickel acting as the catalyst.