In this paper, a novel, selective and sensitive high performance liquid chromatography-UV photolysis-fluorescence detection (HPLC-UV-FLD) method for nitrosamines (NAs) is proposed based on terbium-doped carbon dots (Tb-CDs). Experimental studies have shown that nitrosamines can be degraded by UV photolysis with wavelength at 254 nm to produce NO2−, while NO2− can rapidly and specifically quench the fluorescence of Tb-CDs. Based on this principle, N-nitrosodimethylamine (NDMA), Nnitrosomorpholine (NMor), N-nitrosopyrrolidine (NPYR), N-nitrosodiethylamine (NDEA) and N-nitrosopiperidine (NPIP) are separated within 8 min by HPLC. These five kinds of NAs showed a good linear relationship in the range of 10–2000 μg/L, and the limit of detection was as low as 2.25 μg/L. The proposed method is successfully applied to the detection of sweet potato, lotus root, potato, water chestnut, tomato and cucumber. The sample recoveries range from 77.35 % to 119.3 %.