Tungsten disulfide (WS2) has broad applications due to its unique molecular structure and outstanding physicochemical properties. In particular, the physical barrier properties of WS2 make it suitable to act as barriers against hydrogen. Herein, WS2-Ni composite coatings are prepared by electrodeposition to mitigate hydrogen-induced damage of X70 pipeline steel. The influence of the WS2 concentration on the hydrogen resistance of coating is assessed by electrochemical hydrogen permeation test, hydrogen adsorption simulation, slow strain rate tensile test (SSRT), and fracture analysis. As the WS2 concentration increases, the distributions of WS2 in the coatings transition from sparse to uniform and then agglomeration, while the grain size of Ni decreases initially and then decreases. These microstructural changes impact the hydrogen adsorption sites and diffusion paths, leading to a non-linear relationship between the hydrogen permeation resistance and WS2 concentration. This similar concentration dependence is also observed from the hydrogen embrittlement (HE) resistance of coatings, suggesting that enhancing the hydrogen permeation resistance can improve the HE resistance. This study highlights the great potential of WS2 as an effective barrier against hydrogen permeation, and the results provide insights into the hydrogen protection mechanism of pipeline steel.