Actinic keratosis (AK) is a common precancerous skin lesion with significant harm, and it is often confused with non-actinic keratoses (NAK). At present, the diagnosis of AK mainly depends on clinical experience and histopathology. Due to the high difficulty of diagnosis and easy confusion with other diseases, this article aims to develop a convolutional neural network that can efficiently, accurately, and automatically diagnose AK. This article improves the MobileNet model and uses the AK and NAK images in the HAM10000 dataset for training and testing after data preprocessing, and we performed external independent testing using a separate dataset to validate our preprocessing approach and to demonstrate the performance and generalization capability of our model. It further compares common deep learning models in the field of skin diseases (including the original MobileNet, ResNet, GoogleNet, EfficientNet, and Xception). The results show that the improved MobileNet has achieved 0.9265 in accuracy and 0.97 in Area Under the ROC Curve (AUC), which is the best among the comparison models. At the same time, it has the shortest training time, and the total time of five-fold cross-validation on local devices only takes 821.7 s. Local experiments show that the method proposed in this article has high accuracy and stability in diagnosing AK. Our method will help doctors diagnose AK more efficiently and accurately, allowing patients to receive timely diagnosis and treatment.