Although stir bar sportive extraction was thought to be a highly efficiency and simple pretreatment approach, its wide application was limited by low selectivity, short service life, and relatively high cost. In order to improve the performance of the stir bar, molecular imprinted polymers and magnetic carbon nanotubes were combined in the present study. In addition, two monomers were utilized to intensify the selectivity of molecularly imprinted polymers. Fourier transform infrared spectroscopy, scanning electron microscopy, and selectivity experiments showed that the molecularly imprinted polymeric stir bar was successfully prepared. Then micro-extraction based on the obtained stir bar was coupled with HPLC for determination of trace cefaclor and cefalexin in environmental water. This approach had the advantages of stir bar sportive extraction, high selectivity of molecular imprinted polymers, and high sorption efficiency of carbon nanotubes. To utilize this pretreatment approach, pH, extraction time, stirring speed, elution solvent, and elution time were optimized. The LOD and LOQ of cefaclor were found to be 3.5 ng · mL–1 and 12.0 ng · mL–1, respectively; the LOD and LOQ of cefalexin were found to be 3.0 ng · mL–1 and 10.0 ng · mL–1, respectively. The recoveries of cefaclor and cefalexin were 86.5 ~ 98.6%. The within-run precision and between-run precision were acceptable (relative standard deviation <7%). Even when utilized in more than 14 cycles, the performance of the stir bar did not decrease dramatically. This demonstrated that the molecularly imprinted polymeric stir bar based micro-extraction was a convenient, efficient, low-cost, and a specific method for enrichment of cefaclor and cefalexin in environmental samples.