Abstract We report for the first time the frequency locking of an extended-cavity quantum-cascade-laser (EC-QCL) to a near-infrared frequency comb. The locked laser source is exploited to carry out molecular spectroscopy around 7.8 μm with a line-centre frequency combined uncertainty of ~63 kHz. The strength of the approach, in view of an accurate retrieval of line centre frequencies over a spectral range as large as 100 cm−1, is demonstrated on the P(40), P(18) and R(31) lines of the fundamental rovibrational band of N2O covering the centre and edges of the P and R branches. The spectrometer has the potential to be straightforwardly extended to other spectral ranges, till 12 μm, which is the current wavelength limit for commercial cw EC-QC...