The efficient interleaved boost converter (IBC) combined with the 3-level neutral point clamped (NPC) inverter for grid-connected photovoltaic systems (GCPVS) maximizes solar energy efficiency are presented. The proposed hybrid technique implies the combination of Double Attention Convolutional Neural Network (DACNN) and Starling Murmuration Optimization (SMO) algorithm and is usually referred as DACNN-SMO technique. Enhancing power quality at the Point of Common Coupling (PCC) while utilizing the rated capacity of the inverter into consideration is the main goal of the proposed approach. The grid-connected photovoltaic system additionally includes an efficient three-level NPC inverter and interleaved boost converter to decrease DC link voltage oscillation. In addition to preventing overheating, the inverter current controls reactive power adjustment, active power injection, and current harmonic filtering. Utilizing the SMO technique, By employing the SMO technique, the system effectively regulates output voltage, ensuring that the inverter output voltage. The DACNN enhances the system’s ability to monitor and diagnose faults. Using MATLAB, the proposed topology is implemented, and the results are contrasted with those of other existing techniques. The existing methods such as Heap Based Optimizer (HBO), Circle Search Algorithm (CSA) and Sparrow Search Algorithm (SSA) attains a higher THD of 3.7%, 4.7% and 5.3% respectively. The proposed method DACNN-SMO attains a THD of 2.5%. The proposed technique displays the efficiency is 99.86%. When compared to existing strategies, the proposed technique displays lower THD and high efficiency.