Abstract In view of the preparation of heterocyclic polymethine dyes, 2-(methylpyridyl or quinolyl)-benz-X-azoles were synthesized with the general reaction between carboxylic acids (or derivatives) and o-bifunctional compounds. The electronic spectra and the methyl proton chemical shifts are briefly discussed.