We report on a novel sensing technique combining photonics and microelectromechanical systems (MEMS) for the detection and monitoring of gas emissions in environmental, medical, and industrial applications. We discuss how MEMS-tunable vertical-cavity surface-emitting lasers (VCSELs) can be exploited for in-situ detection and NIR spectroscopy of several gases, such as O 2, N2O, CH4, HF, HCl, etc., with estimated sensitivities between 0.1 and 20 ppm on footprints ≪ 10-3 mm 3. The VCSELs can be electrostatically tuned with a continuous wavelength shift up to 20 nm, allowing for unambiguous NIR signature determination. Selective concentration analysis in heterogeneous gas compositions is enabled, thus paving the way to an integrated optical platform for multiplexed gas identification by bandgap and device engineering. We will discuss here, in particular, our efforts on the development of a 760 nm AlGaAs-based tunable VCSEL for O2 detection.