As is well known, the leakage of four toxic gases, NO
2, NH
3, mustard gas and sarin greatly threaten the environment and human health. Among of them, mustard gas and sarin are two serious chemical and biological weapons agents, and exposure to a small amount can cause skin burns and immediate death. NO
2and NH
3are two common toxic pollutants produced by automobile exhaust, coal combustion and petrochemical industry. The presence of trace amounts of NO
2and NH
3gas in human tissues can cause serious respiratory diseases and damage human brain and other systems. Thus, it is very important to realize the rapid detection of NO
2, NH
3, mustard gas and sarin in academia and industry. In this study, we use density functional theory to investigate the ability of a transition metal Mo doped two-dimensional VS
2structure to detect the four representative toxic gases. The results reveal that Mo atom doping has a significant effect on the stability and gas-sensitivity of the VS
2structure. The Mo atom can be successfully doped on the S-vacancy in the two-dimensional VS
2structure. Compared with the undoped structure VS
2, the doped structure Mo-VS
2has strong interaction with NO
2, NH
3, sarin, and mustard gas, realizing effective adsorption of them. The presence of Mo atom in the VS
2lattice changes the electronic structure of VS
2, also modifies its band gap and density of states. The interaction between the Mo-VS
2structure and the target analytes depends strongly on the nature of the gas molecule. The binding energy values for NO
2, NH
3, mustard gas, and sarin on the Mo-VS
2are significantly higher than those on the pristine VS
2, indicating stronger interaction between the Mo-VS
2structure and these gases. Our calculations show that the Mo atom in VS
2changes its electrical resistance after being exposed to the gases, which can be used to distinguish different gases. Moreover, differences in charge redistribution within the Mo-VS
2structure upon being exposed to different gases can be used to explain their differential gas-sensitivity. Our results can provide sufficient theoretical basis for experimental researchers to design and optimize the performances of sensors in practical applications.