Our findings suggest an intricate interplay between the genes CYP2D6, HNF4A, and IL6 in AS and CA liver cancer patients. Here, CYP2D6 is linked to liver cancer.