On-loan Sunderland striker Ji Dong-won scored to help Augsburg beat the drop in the Bundesliga today.
Fortuna Dusseldorf were relegated as Hoffenheim and Augsburg staged final-day escape acts.
Dusseldorf went down 3-0 at Hannover to finish the season second bottom of the table, with their two relegation rivals both ending their campaigns with victories.
Mame Diouf put Hannover ahead in the 36th minute and Didier Ya Konan put the result beyond doubt with a second-half double.
The visitors could not muster any sort of response as their fifth straight defeat, and eighth in 10 league games, condemned them to an immediate return to the second tier.
Hoffenheim, who started the day two points behind Dusseldorf, scored two late goals to win 2-1 at Champions League finalists Borussia Dortmund and make the relegation play-offs.
Things looked bleak for the visitors when Robert Lewandowski put them behind after six minutes, but Sejad Salihovic equalised with a penalty in the 77th minute.
Three minutes later, Dortmund goalkeeper Roman Weidenfeller saw red for bringing down Sven Schipplock when he was through on goal and, with no more substitutions left, winger Kevin Grosskreutz went in goal for the resulting penalty.
Salihovic took it again, and scored again, to complete the comeback.
Hoffenheim now face Kaiserslautern, who came third in the second tier, in a two-legged play-off for the right to stay in the Bundesliga.
Augsburg guaranteed their top-flight status with a 3-1 win at home to relegated Greuther Furth, a result which lifted them out of the bottom three for the first time all season.
Tobias Werner put the hosts ahead after 30 minutes after Edgar Prib had seen a penalty saved at the other end, and Jan-Ingwer Callsen-Bracker made it two 10 minutes after the break.
Florian Trinks made things nervous for Augsburg by halving the deficit just after the hour mark, but Ji – who joined Augsburg on loan from Sunderland in January – allowed them to breathe easy with a third 15 minutes from time.
* Don’t miss your 40-page Football Echo, with the biggest and best coverage of SAFC, plus much more. It’s out tomorrow morning.