The chemosensory system has experienced relevant changes in subterranean animals, facilitating the orientation into darkness via the perception of specific chemical signals critical to survive in this particular environment. However, the genomic basis of chemoreception in cave-dwelling fauna is largely unexplored. We generated de novo transcriptomes for antennae and body samples of the troglobitic beetle Speonomus longicornis (whose characters suggest an extreme adaptation to the deep subterranean) in order to interrogate the evolutionary origin and diversification of the chemosensory gene repertoire across coleopterans through a phylogenomic approach. Our results suggested a diminished diversity of odorant and gustatory gene repertoires compared to polyphagous epigean beetles. Moreover, S. longicornis showed a large diversity of odorant-binding proteins, suggesting an important role of these proteins in capturing airborne chemical cues. We identified a gene duplication in the ionotropic co-receptor IR25a, a highly conserved single-copy gene in protostomes involved in thermal and humidity sensing. In addition, no homologous genes to sugar receptors or the ionotropic receptor IR41a were detected. Our findings suggest that the chemosensory gene repertoire of this cave beetle may have been reshaped by the low complexity of chemical signals of this particular environment, and that gene duplication and loss may have played an important role in the evolution of genes involved in chemoreception. Altogether, our results shed light on the genomic basis of chemoreception in a cave-dwelling invertebrate and pave the road towards understanding the genomic underpinnings of adaptation to the subterranean lifestyle at a deeper level.