Mainz led 3:0 after the first 45 minutes. Dominik Kor opened the scoring for the visitors in the 15th minute, and at the end of the half hour of play Nebel doubled the lead.
At the end of the first half, Sheraldo Becker scored for an unreal 3:0.
He then brought on Kompany from the bench for Oliseh, Kane and Musial. They all scored, and with Jackson's goal, the champions completed their turnaround.
Bayer Leverkusen won 2-1 away against Cologne, and remained in the race for Champions League qualification.
Both goals were scored by Schick, Walschmidt reduced the deficit in the final minutes, but Bayer held on.
Heidenheim beat St. Pauli 2-0 and kept their chances of survival alive. Wolfsburg and Borussia Monchengladbach played out a goalless draw, while Augsburg and Eintracht drew 1-1.