Ferns, known for their adaptability and widespread presence, form a diverse group of plants. However, the mechanisms underlying terpenoid production, which are often linked to plant adaptation, are not well understood in ferns. Here, we report that Dryopteris fragrans (D. fragans) produces diverse terpenoids in glandular trichomes (GTs) through the activities of microbial-type terpene synthases. Using microscopy methods, capitate GTs were found to occur on various organs throughout the development of D. fragrans. In D. fragrans leaves, 13 terpenoids, most being sesquiterpenoids, were identified. By comparing the terpenoid chemistry of intact leaves, GT-removed leaves, and isolated GTs, GTs were concluded to be the main site of terpenoid storage. Next, transcriptomes of D. fragrans leaves and GTs were created and mined for genes of the terpenoid biosynthetic pathway. Among them were nine putative full-length microbial terpene synthase-like (MTPSL) genes designated DfMTPSL1–9. Using in vitro enzyme assays, six of the nine DfMTPSLs were demonstrated to have sesquiterpene synthase activities. Of them, DfMTPSL1 catalyzes the formation of (−)-9-epi-presilphiperfolan-1-ol, the most abundant sesquiterpenoid in leaves. DfMTPS2 produces α-muurolene, another major sesquiterpenoid from D. fragrans. The catalytic activities of DfMTPSLs together with the GT-enriched expression of their respective genes support that GTs are also the main site of terpenoid biosynthesis in D. fragrans. Methyl jasmonate treatment induced the expression of DfMTPSL genes and the emission of terpenoid volatiles, suggesting that GT-produced terpenoids play a role in defense against biotic stresses in D. fragrans, similar to their counterparts in seed plants.