Headspace–gas chromatography–ion mobility spectrometry (HS-GC-IMS) coupled with principal component analysis (PCA) was used to investigate the differences in volatile organic compounds (VOCs) in four different varieties of Yunnan Huang Tian Ma (containing both winter and spring harvesting times), Yunnan Hong Tian Ma, Yunnan Wu Tian Ma, and Yunnan Lv Tian Ma. The results showed that the flavor substances of different varieties and different harvesting times of Rhizoma gastrodiae were mainly composed of aldehydes, alcohols, ketones, heterocycles, esters, acids, alkenes, hydrocarbons, amines, phenols, ethers, and nitrile. Among them, the contents of the aldehydes, alcohols, ketones, and heterocyclic compounds are significantly higher than those of other substances. The results of cluster analysis and fingerprint similarity analysis based on principal component analysis and Euclidean distance showed that there were some differences between different varieties of Yunnan Rhizoma gastrodiae and different harvesting times. Among them, Yunnan Lv Tian Ma and Wu Tian Ma contained the richest volatile components. Winter may be the best harvesting season for Tian Ma. At the same time, we speculate that the special odor contained in Tian Ma should be related to the aldehydes it is rich in, especially benzene acetaldehyde, Benzaldehyde, Heptanal, Hexanal, Pentanal, and butanal, which are aldehydes that contain a strong and special odor and are formed by the combination of these aldehydes.