Diaphania indica (Lepidoptera: Crambidae) is one of the most important pests infesting many cucurbitaceous vegetables. During the rearing of insect eggs, we observed a fungal infection in these insect eggs which causes the death of pests. Therefore, this work aimed to isolate and identify this fungus by amplifying the internal transcribed spacer (ITS) region of the rDNA, as well as evaluating the efficiency of this fungus in control. Aspergillus flavus, ‘PP125556’, showcased robust pathogenicity against a range of D. indica pests. The results showed that colonies of ‘PP125556’ cultivated on potato dextrose agar (PDA) exhibited distinctive morphological characteristics, transitioning from pristine white to verdant green. Bioassays demonstrated concentration-dependent mortality rates of D. indica larvae and adults when exposed to varying concentrations of ‘PP125556’ conidia, with the highest concentration (1 × 109 conidia/mL) inducing significant death, with the highest mortality (53.06% for eggs, 70.57% for larvae, and 86.65% for adults). Furthermore, examination under a stereomicroscope revealed conspicuous external symptoms in infected larvae, including reduced mobility, darkened body pigmentation, and the emergence of white hyphae, indicative of mortality. Additionally, infected eggs exhibited inhibited hatching and the emergence of green hyphae, while infected adults displayed mortality and white hyphae colonization, underscoring the potent biocontrol efficacy of A. flavus ‘PP125556’ against D. indica across diverse developmental stages.