Borussia Dortmund hit four past Mainz,whose showing was a brace from Shinji Okazaki, in a 4-2 win on Saturday afternoon at Signal Iduna Park.
Milos Jojic and Robert Lewandowski's goals were cancelled out by Okazaki before Lukasz Piszczek put Dortmund ahead and Marco Reus scored from the penalty spot to seal the tie.
Dortmund have won their last four games, having booked their German Cup final spot with Bayern on May 17.
This means Bayern and Dortmund have qualified directly for next season's Champions League by virtue of reaching the final and seventh placed Mainz now find themselves in the European spots as a result.
Dortmund drew first blood in the sixth minute with Milos Jojic's right footed shot from outside the box hitting the bottom left corner of the net, following a corner.
In the 12th minute, Marco Reus slipped a pass to Henrikh Mkhitaryan. Mkhitaryan unleashed a powerful shot from just outside the box, but his shot was blocked.
In the 14th minute Shinji Okazaki brought Mainz back into the game. Okazaki hit a right footed shot from outside the box that dipped into the bottom right corner of the net.
Lukasz Piszczek released a right footed shot in the 17th minute from the right side of the box that narrowly missed to the right of the goals.
A minute later Dortmund broke on counter. Mkhataryan played a through ball to Robert Lewandowski. From the centre of the box, Lewandowski hit a right footed shot that hit the centre of the net to put Dortmund ahead.
In the 36th minute, Reus hit a right footed shot from the centre of the box that was close but missed to the left of the goals.
Lewandowski hit a right footed shot in the 41st minute from the right side of the box that went a bit high following an assist from Jojic.
In the 53rd Okazaki hit a right footed shot from the right side of the six yard box that bulged the net in the centre of the goal to level the score for Mainz.
Three minutes later, Dortmund made a swift reply. Following a set piece situation, Reus chipped a cross to Piszczek. Piszczek met the cross with the header from the centre of the box that went into the bottom right corner of the net. 3-2.
Lewandowski hit a right footed shot in the 69th minute from long range on the left that was saved by Loris Karius in the centre of the goal.
In the 79th minute got a penalty that was converted by Reus with a right footed shot to the top left corner.
Pierre-Emerick Aubameyang hit a right shot in the 88th minute from the left side of the box that was saved in the bottom left corner.