Nanostructured tungsten disulfide (WS2) is one of the most promising candidates for being used as active nanomaterial in chemiresistive gas sensors, as it responds to hydrogen gas at room temperature. This study analyzes the hydrogen sensing mechanism of a nanostructured WS2layer using near-ambient-pressure X-ray photoelectron spectroscopy (NAP-XPS) and density functional theory (DFT). The W 4f and S 2p NAP-XPS spectra suggest that hydrogen makes physisorption on the WS2active surface at room temperature and chemisorption on tungsten atoms at temperatures above 150 °C. DFT calculations show that a hydrogen molecule physically adsorbs on the defect-free WS2monolayer, while it splits and makes chemical bonds with the nearest tungsten atoms on the sulfur point defect. The hydrogen adsorption on the sulfur defect causes a large charge transfer from the WS2monolayer to the adsorbed hydrogen. In addition, it decreases the intensity of the in-gap state, which is generated by the sulfur point defect. Furthermore, the calculations explain the increase in the resistance of the gas sensor when hydrogen interacts with the WS2active layer.