Plants generate protective molecules in response to ultraviolet (UV) light. In laboratory experiments, 48 h UV-B irradiation of peach fruits and leaves reduced the flavour-related monoterpene linalool by 60%. No isoprene was detected, but other terpenoids increased significantly, including a threefold accumulation of the sesquiterpene (E,E)-α-farnesene, which was also increased by jasmonic acid treatment. RNA sequencing revealed altered transcript levels for two terpene synthases (TPSs): PpTPS1, a TPS-g subfamily member, decreased by 86% and PpTPS2, a TPS-b subfamily member, increased 80-fold. Heterologous expression in Escherichia coli and transient overexpression in tobacco and peach fruits showed PpTPS1 was localized in plastids and associated with production of linalool, while PpTPS2 was responsible for (E,E)-α-farnesene biosynthesis in the cytoplasm. Candidate regulatory genes for these responses were identified. Commercial peach production in Asia involves fruit bagging to maintain marketable yield and quality. TPS gene expression and volatile terpenoid production in field experiments, using bags transmitting high UV-B radiation, showed similar effects on peach volatiles to those from laboratory experiments. Bags transmitting less UV-B light ameliorated the reduction in the flavour volatile linalool, indicating that flavour components of peach fruits can be modulated by selecting an appropriate source of environmental screening material.