Vismodegib is primarily approved for the treatment of advanced or metastatic basal cell carcinoma, particularly in patients who are not candidates for surgery or radiation. It is also being studied for its potential use in treating other cancers where the Hedgehog pathway is abnormally activated.