Juvenile hormones (JHs) play key roles in regulating metamorphosis and reproduction in insects. The last two steps of JH synthesis diverge depending on the insect order. In Lepidoptera, epoxidation by a P450 monooxygenase precedes esterification by a juvenile hormone acid methyltransferase (JHAMT). In Orthoptera, Dictyoptera, Coleoptera and Diptera epoxidation follows methylation. The aim of our study was to gain insight into the structural basis of JHAMT's substrate recognition as a means to understand the divergence of these pathways. Homology modeling was used to build the structure of Aedes aegypti JHAMT. The substrate binding site was identified, as well as the residues that interact with the methyl donor (S-adenosylmethionine) and the carboxylic acid of the substrate methyl acceptors, farnesoic acid (FA) and juvenile hormone acid (JHA). To gain further insight we generated the structures of Anopheles gambiae, Bombyx mori, Drosophila melanogaster and Tribolium castaneum JHAMTs. The modeling results were compared with previous experimental studies using recombinant proteins, whole insects, corpora allata or tissue extracts. The computational study helps explain the selectivity toward the (10R)-JHA isomer and the reduced activity for palmitic and lauric acids. The analysis of our results supports the hypothesis that all insect JHAMTs are able to recognize both FA and JHA as substrates. Therefore, the order of the methylation/epoxidation reactions may be primarily imposed by the epoxidase's substrate specificity. In Lepidoptera, epoxidase might have higher affinity than JHAMT for FA, so epoxidation precedes methylation, while in most other insects there is no epoxidation of FA, but esterification of FA to form MF, followed by epoxidation to JH III.