FRANKFURT — Volkswagen is set to oust its chief executive, Matthias Müller, as it grapples with a diesel emissions scandal that has cost it billions of dollars, led to the imprisonment of two executives, and scarred the German carmaker’s reputation.

Herbert Diess, who is in charge of the company’s flagship Volkswagen brand, was likely to succeed Mr. Müller, according to two people with knowledge of the internal discussions. The company said earlier on Tuesday that it was considering a leadership change, and a final decision was expected by the end of the week.

While there was no obvious trigger for Mr. Müller’s departure at this moment, his efforts to lead the company beyond the 2015 emissions cheating scandal have stalled.

The repercussions have continued to multiply, tainting not only Volkswagen but also its rivals BMW and Daimler just as they grapple with an industrywide shift toward electric and self-driving vehicles. Political leaders are pressing the German carmakers to compensate diesel owners who bought cars that turned out to be dirtier than advertised, which could add to the already astronomical cost of the scandal.