With the development of deep fusion intelligent control technology and the application of low-carbon energy, the number of renewable energy sources connected to the distribution grid has been increasing year by year, gradually replacing traditional distribution grids with active distribution grids. In addition, as an important component of the distribution grid, substations have a complex internal environment and numerous devices. The problems of untimely defect detection and slow response during intelligent inspections are particularly prominent, posing risks and challenges to the safe and stable operation of active distribution grids. To address these issues, this paper proposes a high-performance and lightweight substation defect detection model called YOLO-Substation-large (YOLO-SS-large) based on YOLOv5m. The model improves lightweight performance based upon the FasterNet network structure and obtains the F-YOLOv5m model. Furthermore, in order to enhance the detection performance of the model for small object defects in substations, the normalized Wasserstein distance (NWD) and complete intersection over union (CIoU) loss functions are weighted and fused to design a novel loss function called NWD-CIoU. Lastly, based on the improved model mentioned above, the dynamic head module is introduced to unify the scale-aware, spatial-aware, and task-aware attention of the object detection heads of the model. Compared to the YOLOv5m model, the YOLO-SS-Large model achieves an average precision improvement of 0.3%, FPS enhancement of 43.5%, and parameter reduction of 41.0%. This improved model demonstrates significantly enhanced comprehensive performance, better meeting the requirements of the speed and precision for substation defect detection, and plays an important role in promoting the informatization and intelligent construction of active distribution grids.