Mono- and sesquiterpenes were used for the traceability of a typical Piedmont (Italy) mountain ricotta cheese produced by nine mountain farms. For each farm a sample of ricotta cheese was collected every 7 days during mountain grazing and analysed using headspace solid-phase microextraction-gas chromatography-mass spectrometry (SPME-GC-MS). Obtained results showed the presence of about 20 monoterpenes (above all alpha-pinene, beta-pinene, camphene, p-cymene, beta-myrcene and limonene) and about 15 sesquiterpenes such as alpha-caryophyllene, alpha-copaene and 9-epi-caryophyllene. Despite a wide concentration variability due to the stages of plant development and the pastured area, there are not able differences between the ricotta cheeses analysed so it is possible with the artificial neural network (ANN) technique to distinguish between different mountain farms.