Carbendazim (CBZ) can protect crops from pathogens, but it is also easy to cause pesticide residues, threatening human health. In our work, an electrochemical sensor based on nitrogen-doped carbon nanohorns (N-CNHs) and polyethyleneimine-modified carbon nanotubes (PEI-CNTs) was developed for the detection of CBZ content in water. The results showed that N-doping provided the CN bonds for CNHs and improved the electrochemical reaction performance of N-CNHs surface. With the participation of PEI, the surface of CNTs was positively charged and contained a large number of NH bonds, which not only promoted the electrostatic assembly of N-CNHs and PEI-CNTs but also was beneficial to further enriching CBZ. After further ultrasound-assisted assembly of N-CNHs and PEI-CNTs, the electron transfer capacity, electrochemical active surface area, and catalytic activity of N-CNHs/PEI-CNTs were significantly improved. The sensor performed a wider linear range (15 nmol/L ~ 70 μmol/L), low detection limit (4 nmol/L) and satisfactory recovery (87.33 % ~ 117.67 %) under the optimal conditions. In addition, the sensor had good anti-interference, reproducibility, and stability. Our work provided a new strategy for quantification of CBZ in environment.