Flavor is one of the most important characteristics of chocolate products and is due to a complex volatile fraction, depending both on the cocoa bean genotype and the several processes occurring during chocolate production (fermentation, drying, roasting and conching). Alkylpyrazines are among the most studied volatiles, being one of the main classes of odorant compounds in cocoa products. In this work, a mass spectrometric approach was used for the comparison of cocoa liquors from different countries. A headspace solid-phase microextraction gas chromatography–mass spectrometry method was developed for the qualitative study of the volatile fraction; the standard addition method was then used for the quantitative determination of five pyrazines (2-methylpyrazine, 2,3-dimethylpyrazine, 2,5-dimethylpyrazine, 2,3,5-trimethylpyrazine and tetramethylpyrazine). Satisfactory figures of merit were obtained: Limits of quantitation were in the range 0.1–2.7 ng/g; repeatability and reproducibility varied between 3% and 7% and between 8% and 14%, respectively. The total content of the pyrazines was remarkably different in the considered samples, ranging from 99 to 708 ng/g. Tetramethylpyrazine showed the highest concentration in all samples, with a maximum value of 585 ng/g. A preliminary study was also performed on the nonvolatile fraction using LC–MS/MS, identifying some flavanols such as catechin, epicatechin and procyanidins. Copyright © 2012 John Wiley & Sons, Ltd.