SignificancePheromones are signaling molecules used for chemical communication in social interactions. Although diverse pheromone classes from diverse species have been identified, little is known about how chemical languages evolve. To study the genetic basis underlying natural diversity in animal chemical language, we analyzed the secreted pheromones of 95 whole-genome sequenced wildCaenorhabditis elegansstrains. We characterized the genetic architectures underlying natural differences in the production of 44 ascarosides, which represent the nematode’s primary pheromone class. Our study uncovered “hot spot loci” that broadly impact ascaroside production, as well as inverse correlations between two major classes of ascarosides. Our findings provide insights into how metabolism and chemical communication are coupled in evolution.