The high mortality of colorectal cancer (CRC) patients and the limitations of conventional tumor-node-metastasis (TNM) stage emphasized the necessity of exploring hub genes closely related to carcinogenesis and prognosis in CRC. The study is aimed at identifying hub genes associated with carcinogenesis and prognosis for CRC. We identified and validated 212 differentially expressed genes (DEGs) from six Gene Expression Omnibus (GEO) datasets and the Cancer Genome Atlas (TCGA) database. We investigated functional enrichment analysis for DEGs. The protein-protein interaction (PPI) network was constructed, and hub modules and genes in CRC carcinogenesis were extracted. A prognostic signature was developed and validated based on Cox proportional hazards regression analysis. The DEGs mainly regulated biological processes covering response to stimulus, metabolic process, and affected molecular functions containing protein binding and catalytic activity. The DEGs played important roles in CRC-related pathways involving in preneoplastic lesions, carcinogenesis, metastasis, and poor prognosis. Hub genes closely related to CRC carcinogenesis were extracted including six genes in model 1 (CXCL1, CXCL3, CXCL8, CXCL11, NMU, and PPBP) and two genes and Metallothioneins (MTs) in model 2 (SLC26A3 and SLC30A10). Among them, CXCL8 was also related to prognosis. An eight-gene signature was proposed comprising AMH, WBSCR28, SFTA2, MYH2, POU4F1, SIX4, PGPEP1L, and PAX5. The study identified hub genes in CRC carcinogenesis and proposed an eight-gene signature with good reproducibility and robustness at the molecular level for CRC, which might provide directive significance for treatment selection and survival prediction.