The implementation, performance validation, and testing of a gas-leak optical sensor based on mid-IR quartz-enhanced photoacoustic (QEPAS) spectroscopic technique is reported. A QEPAS sensor was integrated in a vacuum-sealed test station for mechatronic components. The laser source for the sensor is a quantum cascade laser emitting at 10.56 µm, resonant with a strong absorption band of sulfur hexafluoride (SF6), which was selected as a leak tracer. The minimum detectable concentration of the QEPAS sensor is 2.7 parts per billion with an integration time of 1 s, corresponding to a sensitivity of leak flows in the 10-9 mbar∙l/s range, comparable with state-of-the-art leak detection techniques.