But as they have done so often this season, Heidenheim completely flipped the script in the second-half and Bayern simply had no answers. Kevin Sessa went through on goal before coolly finishing past Sven Ulreich as the Bayern defence was caught napping.
Moments later, it was 2-2 as Tim Kleindienst fired home from Jan-Niklas Beste's cross after being left with acres of space inside the box.
Bayern looked for a response, but it was Heidenheim who struck the knockout blow. It was Kleindienst who completed the comeback for the home side, taking advantage of more shambolic defending from the Rekordmeister.
The result, combined with Bayer Leverkusen's win over Union Berlin, means that Bayern Munich's decade-long reign atop the Bundesliga charts is about to come to an end. Xabi Alonso's side can wrap up the title next weekend.
As for Bayern, attentions will now turn to the UEFA Champions League quarterfinals where Arsenal await. And if they play like they did against Heidenheim, they could be on the receiving end of another humbling result on Tuesday.