VfB Stuttgart captain Wataru Endo headed a dramatic injury-time winner Saturday to ensure his club's survival in the German top flight.

Stuttgart's 2-1 victory at home to FC Koln on the final day of the Bundesliga earned three vital points and a 15th-place finish, one spot above the relegation playoff.

Wataru Endo of VfB Stuttgart reacts after scoring an injury-time winner in a Bundesliga football match against FC Koln in Stuttgart, Germany, on May 14, 2022. (Kyodo)

On track for a draw that would see them finish 16th, Stuttgart made the breakthrough from a corner kick in the 92nd minute.

Endo's Samurai Blue teammate, defender Hiroki Ito, flicked the ball toward the back post, where the captain headed it high into the net, sending the home fans at Mercedes-Benz Arena into rapture.

"It's unbelievable how the stadium exploded. I can't be any happier," said Endo, who thanked the jubilant Stuttgart supporters from the pitch after the full-time whistle.

The 29-year-old midfielder said he was determined to remain at the highest level of club competition leading into the World Cup, kicking off in November in Qatar, where Japan will be pitted against tough Group E opponents Germany and Spain.

"I had a strong desire to play in the first division next season, and that was the most important thing," he said.

Elsewhere in the Bundesliga, Genki Haraguchi assisted on Union Berlin's opener in a 3-2 win at home to Bochum that secured a fifth-place finish and Europa League berth. Takuma Asano registered an assist for Bochum, who finished 13th.

Masaya Okugawa played the full 90 minutes in Arminia Bielefeld's 1-1 draw with visiting RB Leipzig. Bielefeld dropped to the second division following a 17th-place finish.

Daichi Kamada made a full appearance, while Makoto Hasebe came off the bench in the second half for Eintracht Frankfurt, who finished 11th following a 2-2 draw away to Mainz.

Frankfurt will battle Scottish Premiership side Rangers in the Europa League final on Wednesday.

In the Scottish top flight, Kyogo Furuhashi bagged his 19th and 20th goals in all competitions this season for recently crowned champions Celtic, who thrashed Motherwell 6-0 in the final round.