In response to the difficulty of detecting and classifying pests and vegetable and fruit leaves with pests and diseases, this study proposes a novel vegetable and fruit leaf pest detection method called deep block attention SSD (DBA_SSD) for the identification of pests and diseases and classification of the degree of pests and diseases of vegetable and fruit leaves. We propose three vegetable and fruit leaf pest detection methods, namely, squeeze-and excitation SSD (Se_SSD), DB_SSD, and DBA_SSD. Se_SSD fuses SSD feature extraction network and attention mechanism channel, DB_SSD improves VGG feature extraction network, and DBA_SSD fuses the improved VGG network and channel attention mechanism. To reduce the training time and accelerate the training process, the convolutional layers trained in the Image Net image dataset by the VGG model are migrated to this model, whereas the collected vegetable and fruit disease image dataset is randomly divided into training set, validation set, and test set in the ratio of 8:1:1. In addition, data enhancement methods, such as histogram equalization and horizontal flip were used to expand the image data. The performance of the three improved algorithms is compared and analyzed in the same environment and with the classical target detection algorithms YOLOv4, YOLOv3, Faster RCNN, and YOLOv4 tiny. Experiments show that DBA_SSD outperforms the two other improved algorithms, and its performance in comparative analysis is superior to other target detection algorithms.