Ipilimumab is primarily used in the treatment of melanoma, particularly advanced melanoma that cannot be removed by surgery or has metastasized. It is also being studied and used in combination with other drugs for other types of cancers, such as non-small cell lung cancer (NSCLC), renal cell carcinoma, and colorectal cancer.