Abstract Benzaldehyde (BAld) is one of the most widely distributed volatiles that contributes to flavor and defense in plants. Plants regulate BAld levels through various pathways, including biosynthesis from trans-cinnamic acid (free BAld), release from hydrolysis of glycoside precursors (BAld-H) via multiple enzymatic action steps, and conversion into downstream chemicals. Here, we show that BAld-H content in peach (Prunus persica) fruit is up to 100-fold higher than that of free BAld. By integrating transcriptome, metabolomic and biochemical approaches, we identified glycoside hydrolase PpGH28BG1 as being involved in the production of BAld-H through the hydrolysis of glycoside precursors. Overexpressing and silencing of PpGH28BG1 significantly altered BAld-H content in peach fruit. Transgenic tomatoes heterologously expressing PpGH28BG1 exhibited a decrease in BAld-H content and an increase in SA accumulation, while maintaining fruit weight, pigmentation, and ethylene production. These transgenic tomato fruits displayed enhanced immunity against Botrytis cinerea compared to wild type (WT). Induced expression of PpGH28BG1 and increased SA content were also observed in peach fruit when exposed to Monilinia fructicola infection. Additionally, elevated expression of PpGH28BG1 promoted fruit softening in transgenic tomatoes, resulting in a significantly increased emission of BAld compared to WT. Most untrained taste panelists preferred the transgenic tomatoes over WT fruit. Our study suggests that it is feasible to enhance aroma and immunity in fruit through metabolic engineering of PpGH28BG1 without causing visible changes in the fruit ripening process.