Sofosbuvir is used in combination with other antiviral drugs for treatment of patients with viral infection that damages the liver (Hepatitis C) including those patients who have human immunodeficiency virus (HIV) infection or liver cancer or are awaiting a liver transplant.