Nine-man Borussia Dortmund suffered a spectacular 4-2 home defeat against derby rivals Schalke on Saturday to hand the initiative to Bundesliga leaders Bayern Munich.
Daniel Caligiuri's double for previously struggling Schalke in a thrilling game meant Dortmund stayed a point behind Bayern, who visit second-bottom Nuremberg in a game in hand on Sunday.
The two sides will have three games left after this weekend in the closest German title race in years.
Third-placed RB Leipzig secured a Champions League berth next term with a 2-1 win over Freiburg, Eintracht Frankfurt in fourth drew 0-0 with Hertha Berlin, bottom side Hanover beat Mainz 1-0 and Fortuna Dusseldorf hammered Werder Bremen 4-1.
Dortmund began brightly and opened the scoring on 14 minutes when Jadon Sancho floated in an imaginative chipped cross and Mario Goetze headed in.
England winger Sancho was then struck in the eye with what appeared to be a lighter thrown from the crowd during the celebrations but was able to continue.
Schalke soon levelled in controversial circumstances, Caligiuri converting a penalty after Julian Weigl was punished for handball after video review.
The decision was fiercely protested by Dortmund's players with Weigl having little time to react to a deflection.
Salif Sane then put Schalke into the lead on 28 minutes with a powerful header from a corner.
In an end-to-end contest, Dortmund captain Marco Reus was sent off on the hour for catching Suat Serdar on the ankle with his studs and Caligiuri expertly curled the ensuing free-kick into the top corner.
Dortmund were then reduced to nine men after Marius Wolf was dismissed in carbon copy fashion to Reus.
The Schalke win was only their second in 13 league games and pushes last term's runners-up further away from the relegation play-off spot.
Hosts Leipzig made sure they will return to the Champions League after last term's foray with in-form Timo Werner netting on 19 minutes and Emil Forsberg adding a second-half penalty.
In between, Leipzig goalkeeper Peter Gulasci was beaten by Vincenzo Grifo's free-kick as he was still stood by his post lining up his wall when the kick was allowed to be taken.
Leipzig's achievement has come with sporting director Ralf Rangnick filling in as coach before Hoffenheim's Julian Nagelsmann joins in July.
Mid-table Dusseldorf, the surprise packages this season after promotion, also stunned Bremen in just the first minute when Benito Raman slotted home.
Kenan Karaman then went on a superb mazy run to score the second.
Max Kruse pulled one back from the spot but Rouwen Hennings headed in and Markus Suttner scored the fourth to condemn eighth-placed Bremen, who are now struggling for a Europa League spot - days after a controversial defeat by Bayern in the German Cup semi-final.
A terrible error from Mainz keeper Florian Mueller allowed Hendrik Weydandt to score and keep Hanover's hopes of survival alive.
Third-bottom Stuttgart, three points above Nuremberg and Hanover in the relegation play-off spot, host fifth-placed Borussia Moenchengladbach in Saturday's late game.
Seventh-placed Hoffenheim, who after the win by Cup finalists Leipzig are in an additional Europa League qualifying spot, host Wolfsburg on Sunday.dpa