BackgroundHepatocellular carcinoma (HCC) poses a significant global health challenge due to its poor prognosis and limited therapeutic modalities. Anoikis and ErbB signaling pathways are pivotal in cancer cell proliferation and metastasis, but their relevance in HCC remains insufficiently explored.MethodsThis study evaluates the prognostic significance of anoikis and ErbB signaling pathways in HCC by utilizing data from The Cancer Genome Atlas (TCGA), the International Cancer Genome Consortium (ICGC), three additional independent validation cohorts, and an in-house cohort. Advanced bioinformatics analyses and 167 machine learning models based on leave-one-out cross-validation (LOOCV) were used to predict HCC prognosis and assess outcomes of immune-targeted therapies. Additionally, key biological processes of the anoikis and ErbB signaling pathways in HCC were further investigated.ResultsThe single sample Gene Set Enrichment Analysis revealed a strong correlation between upregulated ErbB signaling in high anoikis-expressing tumors and poor clinical outcomes. The development of the Anoikis-ErbB Related Signature (AERS) using the LASSO + RSF model demonstrated robust predictive capabilities, as validated across multiple patient cohorts, and proved effective in predicting responses to immune-targeted therapies. Further investigation highlighted activated NOTCH signaling pathways and decreased macrophage infiltration was associated with resistance to sorafenib and immune checkpoint inhibitors, as evidenced by bulk and single-cell RNA sequencing (scRNA-seq).ConclusionAERS provides a novel tool for clinical prognosis and paves the way for immune-targeted therapeutic approaches, underscoring the potential of integrated molecular profiling in enhancing treatment strategies for HCC.