Although Bayern Munich had long since wrapped up the title - and Schalke second spot for that matter - there were all manner of possible final-day permutations involving Borussia Dortmund, Hoffenheim, Bayer Leverkusen and RB Leipzig in the race for the European places. At the other end of the table Freiburg, Wolfsburg and Hamburg were battling to stay in the top flight.
The title had long since been sealed, but the champions were beaten 4-1 by Stuttgart at the Allianz Arena on the final day, a result that had ramifications further down the standings. Not that it stopped the Bavarians partying in style, though.
Watch: Check out Bayern's title celebrations under the Munich sunshine!
The Royal Blues had also wrapped up second place - and a return to the UEFA Champions League for the first time since 2015 - prior to the final day, but a 1-0 final-day win at home against Eintracht Frankfurt damaged the Eagles' European hopes.
So here's where it started to get a little bit complicated. Hoffenheim knew the equation going into the final day: beat Borussia Dortmund by two goals to finish third. Julian Nagelsmann's side duly did so, running out 3-1 winners, and secured a spot in the UEFA Champions League group stages for the first time ever.
If Hoffenheim beat Dortmund, how did BVB end up fourth and in the Champions League? Fortunately for Borussia, even a defeat by a two-goal margin was enough assuming Bayer Leverkusen did not beat Hannover by at least five goals. Die Werkself won 3-2, meaning even Dortmund's 3-1 defeat was enough for fourth place. Marco Reus still wasn't happy, though.
Watch: Reus demands change at BVB, despite top-four finish
Leverkusen needed to better Hoffenheim's result against BVB to finish fourth. Since Nagelsmann's side won 3-1, Bayer required victory by five goals to overturn Hoffenheim's superior goal difference and secure a top-four berth, but only won 3-2 against Hannover. Despite ending level on points with Hoffenheim and Dortmund, Leverkusen finish the season in fifth - and in the UEFA Europa League - due to a worse goal difference (+14).
6) RB Leipzig
Leipzig won 6-2 against Hertha Berlin, but only defeats for Hoffenheim and Leverkusen would have secured fourth place. As it is, RB will enter the Europa League, although at what stage remains to be seen: if Eintracht Frankfurt - who finished eighth and outside the European spots - win the DFB Cup, then Leipzig enter the Europa League at the second qualifying stage. If Bayern Munich win the DFB Cup, the Easterners go straight into the group stages and Stuttgart (seventh) enter the second qualifying stage.
Stuttgart were the big winners on the final day: Tayfun Korkut's side sensationally emerged 4-1 victors at Bayern. That, combined with Eintracht Frankfurt's and Borussia Mönchengladbach's defeats, meant the Swabians jumped into seventh. VfB will now be praying for Bayern to beat Eintracht in the DFB Cup final: if they do that, Stuttgart enter the Europa League at the second qualifying round stage, and Leipzig go into the group stages. If Frankfurt win, there will be no European football at the Mercedes-Benz Arena next season.
Frankfurt needed to better Leipzig's result for a place in the top six. As it panned out, the Eagles lost 1-0 to Schalke and slipped out of the Europa League spots completely due to Stuttgart's win in Munich. If Eintracht win the DFB Cup against Bayern, they go straight into the Europa League group stages. If they lose the DFB Cup final, there will be no European football in Frankfurt, with Stuttgart instead moving into the second qualifying round and Leipzig into the group stages.
Gladbach lost 2-1 in Hamburg, but even if they had won, they needed both Frankfurt and Stuttgart to drop points to finish seventh.
Cologne were guaranteed to finish bottom, but one automatic relegation position was yet to be confirmed with either Wolfsburg or Hamburg set to join the Billy Goats. Those two and Freiburg were the only teams who could contest the relegation play-off against Holstein Kiel.
Freiburg's win meant Wolfsburg needed to match Hamburg's result to ensure a play-off spot. A 4-1 win for the Wolves against relegated Cologne secured 16th place and a double-header against Holstein Kiel, third in Bundesliga 2.
Hamburg have been relegated for the first time in their history: HSV beat Gladbach 2-1 - as they had to - but Wolfsburg's win against relegated Cologne consigned Christian Titz's side to a maiden relegation.