Selected ion flow tube mass spectrometry (SIFT-MS) has been used to analyse on-line and in real time the exhaust gas emissions from a Caterpillar 3304 diesel engine under different conditions of load (idle and 50% of rated load) and speed (910, 1500 and 2200 rpm) using three types of fuel: an ultra-low-sulphur diesel, a rapeseed methyl ester and gas oil. SIFT-MS analyses of the alkanes, alkenes and aromatic hydrocarbons in the headspace of these fuels were also performed, but the headspace of the rapeseed methyl ester consists mainly of methanol and a compound with the molecular formula C4H8O. The exhaust gases were analysed for NO and NO2 using O reagent ions and for HNO2 using H3O+ reagent ions. The following aldehydes and ketones in the exhaust gases were quantified by using the combination of H3O+ and NO+ reagent ions: formaldehyde, acetaldehyde, propenal, propanal, acetone, butanal, pentanal, butanone and pentanone. Formaldehyde, acetaldehyde and pentenal, all known respiratory irritants associated with sensitisation to asthma of workers exposed to diesel exhaust, are variously present within the range 100–2000 ppb. Hydrocarbons in the exhaust gases accessible to SIFT-MS analyses were also quantified as total concentrations of the various isomers of C3H4, C3H6, C4H6, C5H8, C5H10, C6H8, C6H10, C7H14, C6H6, C7H8, C8H10 and C9H12. Copyright © 2004 John Wiley & Sons, Ltd.