Cancer can lead to hepatic impairment through several mechanisms. Primary liver cancers, such as hepatocellular carcinoma, directly affect liver function by destroying healthy liver tissue. Metastasis from other cancers, such as colorectal cancer or breast cancer, can also compromise liver function. Additionally, cancer treatments like chemotherapy, targeted therapy, and immunotherapy can induce hepatotoxicity, further impairing liver function.