Hepatocellular carcinoma (HCC) is the most common neoplasm among all primary liver cancers, and hepatitis B virus (HBV) infection is the leading etiology of HCC worldwide. To identify genes significantly associated with poor survival, along with new insight into the underlying mechanisms and therapeutic targets, we conducted a bioinformatics analysis on HBV-related HCC. First, the microarray datasets GSE121248 and GSE55092 were obtained from the Gene Expression Omnibus database, which were screened for genes differentially expressed in cancer and non-cancer tissues in both datasets according to an adjusted p value < 0.05 and |log fold change| > 1.5. A total of 286 differentially expressed genes (79 up-regulated and 207 down-regulated) were selected for function enrichment analyses, including Gene Ontology terms and Kyoto Encyclopedia of Genes and Genomes (KEGG) pathways. The proteinprotein interaction network and modular analysis were constructed by Cytoscape software. Subsequently, KEGG analysis of 42 hub genes was performed, and Kaplan-Meier plotter and Gene Expression Profiling Interactive Analysis were used to validate the differential expression profile and survival associations. In addition, the Connectivity Map (CMAP) database was used to predict small-molecules with activity that might reverse the biological state of HBV-related HCC. Collectively, these analyses identified nine hub genes (BUB1, BUB1B, CCNB1, CCNB2, CDC20, CDK1, MAD2L1, PTTG1, TTK) in the cell cycle pathway as candidate targets. Moreover, compounds targeting cell cycle arrest and apoptosis such as apigenin, resveratrol, and chrysin were selected as candidates with potential therapeutic application for HBV-related HCC.