Aphids are major insect pests in agriculture and forestry worldwide. Following attacks by natural enemies, many aphids release an alarm pheromone to protect their population. In most aphids, the main component of the aphid alarm pheromone (AAP) is the sesquiterpene hydrocarbon (E)-β-farnesene (EβF). However, the mechanisms behind its biosynthesis and regulation remain poorly understood. In this study, we used the bird cherry–oat aphid Rhopalosiphum padi, which is an important wheat aphid, to investigate the regulatory mechanisms of EβF biosynthesis. Our results showed that EβF biosynthesis occurs during the mature embryo period and the molting period of the 1st- and 2nd-instar nymphs. Triglycerides provide the prerequisite material for EβF production and release. Based on transcriptome sequencing, RNAi analysis, hormone treatments, and quantitative measurements, we found that the biosynthesis of EβF utilizes acetyl coenzyme A produced from fatty acid degradation, which can be suppressed by juvenile hormone but it is promoted by 20-hydroxyecdysone through the modulation of fatty acid metabolism. This is the first systemic study on the modulation of EβF production in aphids. The results of our study provide insights into the molecular regulatory mechanisms of AAP biosynthesis, as well as valuable information for designing potential aphid control strategies.