The introduction of light elements has received considerable attention to improve the efficiency of Ni-based catalysts toward the water gas shift (WGS) reaction, but an understanding of the role of light elements in the catalyzed WGS reaction is rather limited. In this work, the mechanism of the WGS reaction and undesirable coke formation over Ni x P y catalysts (Ni 3 P(001), Ni 12 P 5 (001), and NiP 2 (100) surfaces) is studied by the density functional theory (DFT) method. The adsorption of reactive species (H 2 O, H 2 , OH, O, H, CO, CO 2 , COOH, CHO, and HCOO), Bader charge, electron density difference, and reaction pathways are systematically investigated. The results show that an increase in P content can separate the continuous Ni sites to be more dispersed, increase the charge transfer from Ni to P, and increase the energy barriers of coke formation reactions. But a very high P content is a disadvantage for water dissociation; Ni 12 P 5 (001) is, thus, determined to be the best surface among the calculated ones, both inhibiting carbon deposition and good for water dissociation. For both OH* and H*, P-top sites act as the active sites other than the common Ni-top sites, which is favorable for OH* dissociation and the oxidation of CO to CO 2 . The calculated mechanism and microkinetic modeling for the WGS reaction over Ni 12 P 5 (001) illustrate that the redox pathway is the most favorable, with H 2 O dissociation as the rate-determining step. The microkinetic modeling further confirms that on Ni 12 P 5 (001) the operating temperature of the WGS reaction can be controlled to be lower than that on pure Ni(111), indicating that the introduction of P can decrease the temperature of the catalytic reaction. This study provides a theoretical understanding for the preparation and design of highly effective light-element-introduced Ni-based catalysts for the WGS reaction.