The debate whether the coevolution of plants and insects or macroevolutionary processes (phylogeny) is the main driver determining the arsenal of molecular defensive compounds of plants remains unresolved. Attacks by herbivorous insects affect not only the composition of defensive compounds in plants but also the entire metabolome. Metabolomes are the final products of genotypes and are constrained by macroevolutionary processes, so closely related species should have similar metabolomic compositions and may respond in similar ways to attacks by folivores. We analyzed the elemental compositions and metabolomes of needles from three closely related Pinus species with distant coevolutionary histories with the caterpillar of the processionary moth respond similarly to its attack. All pines had different metabolomes and metabolic responses to herbivorous attack. The metabolomic variation among the species and the responses to folivory reflected their macroevolutionary relationships, with P. pinaster having the most divergent metabolome. The concentrations of terpenes were in the attacked trees supporting the hypothesis that herbivores avoid plant individuals with higher concentrations. Our results suggest that macroevolutionary history plays important roles in the metabolomic responses of these pine species to folivory, but plant-insect coevolution probably constrains those responses. Combinations of different evolutionary factors and trade-offs are likely responsible for the different responses of each species to folivory, which is not necessarily exclusively linked to plant-insect coevolution.