Aristolochic acids (AAs) are known as nephrotoxins found in Aristolochia and Asarum. This paper aims to establish a novel method for the determination of aristolochic acid I (AA-I) and aristolochic acid II (AA-II) in Chinese herbal medicines through derivatization followed by gas chromatography-tandem mass spectrometry (GC–MS/MS). The derivatization reaction was performed by adding 1 mL dimethyl sulfoxide, 10 mg K2CO3 and 10 μL methyl iodide (CH3I) to the sample extracts and reacting in the dark at room temperature for 20 min. The derivatization method had many advantages including mild reaction condition, low cost, simple procedure and short derivatization time. The derivatives were determined by GC–MS/MS and the parameters of selective reaction monitoring (SRM) including quantitative ion pairs, fragmentation voltage and ionization energy were optimized in order to enhance the sensitivity. Method validation and application displayed excellent method performance. The linear correlation coefficients (r2) were 0.9997 and 0.9996, the detection limits were 2.5 ng/g and 3.0 ng/g, the relative standard deviations were 4.0% and 3.6%, and the relative recoveries were 94.62% and 93.55% for AA-I and AA-II, respectively. The results showed that the established method was simple, rapid and sensitive which expanded the application of GC–MS/MS in the detection of aristolochic acids in Chinese herbal medicines.