A facile synthetic method of attapulgite@covalent organic frameworks was reported in this study. The composite was synthesized by covalently grafting covalent organic frameworks (synthesized from 1,3,5-triformylphloroglucinol and p-phenylenediamine) onto attapulgite at room temperature and was characterized by Fourier transform infrared spectroscopy, X-ray diffraction, zeta potential analysis, transmission electron microscopy, scanning electron microscopy, X-ray photoelectron spectroscopy and Brunauer-Emmett-Teller measurement. The synthesized nanocomposite was used as a sorbent in dispersive solid phase extraction to extract pyrethroids from environmental water samples, and the parameters affecting the extraction efficiency were optimized. The linear range of the four pyrethroids was 2.5-500 mu g L-1, and the enrichment factors ranged from 65.0 to 68.2. The method detection limits were between 0.83 and 1.79 mu g L-1 under the optimal conditions. In addition, the intra-day and inter-day precision were 1.4%-4.8% and 2.7%-3.6%, respectively. Finally, the method was successfully applied to extract pyrethroids from real water samples with relative recoveries ranging from 71.2% to 88.7%.