Our study results suggested a potential risk association between HMGCR inhibitors and NPC1L1 with hepatocellular carcinoma and gastric cancer. Here, NPC1L1 is linked to hepatocellular carcinoma.