Hepatocellular carcinoma (HCC), the most prominent type of primary liver cancer, often diagnosed late, leading to poor prognosis and limited treatment options. This study investigated the anti-carcinogenic effect of Quinazoline-2,4(1H,3H)-dione (Qd), a quinazoline derivative of natural origin and identified Qd as an effective compound against HCC via STAT3 and FOXO3a signaling. STAT3 and FOXO3a are two well-known molecular drivers of HCC. In silico findings revealed Qd as the potent candidate due to its highly stable interaction with STAT3 and FOXO3a. To validate its anticancer activity, in vitro experiments were conducted on the HepG2 cell line. Qd exerts cytotoxic effect in HepG2 cells with an IC50 value of 26.07 μM, while being non-toxic in WRL-68 cells at a lower concentrations with an IC50 of 326.5 μM. Morphological changes and apoptotic cell death were confirmed using DAPI staining and Live/Dead assay. Qd also induced ROS-mediated mitochondrial damage. Qd upregulated mRNA expressions of pro-apoptotic and necroptotic markers while downregulating anti-apoptotic marker. Accordingly, the protein expression analysis demonstrated increased levels of Bax, Caspase 3, c-PARP, RIPK1, RIPK3 and MLKL, while decreasing Bcl2 and PARP expressions. Gene and protein expression of STAT3 remained at a basal level while FOXO3a gene expression increased significantly at 5 μM Qd concentration. Significant changes were particularly observed at 5 μM Qd concentration in all in vitro experiments. Despite quinazoline compounds have been shown biological and pharmacological effects, the anticancer effect of Qd is elusive till date. These in silico and in vitro findings highlighted Qd as a potent compound for further exploration in HCC therapy by targeting apoptotic and necroptotic cell death pathways.