Didier Ya Konan scored twice for Hannover, which is trying to avoid relegation.
Schalke's loss means Bayern Munich will remain top of the standings regardless of the outcome of its late game at third-place Bayer Leverkusen.
Schalke lost 2-1 to Bayern last week and is one point behind in the standings. Leverkusen is six points back.
Fourth-place Borussia Dortmund also lost, going down 1-0 at Mainz.
Werder Bremen thrashed Freiburg 4-0, Stuttgart beat Hertha Berlin 1-0 and Cologne won 2-0 at Hoffenheim.
Schalke overcame a two-goal deficit with two quick goals at the start of the second half but Hannover hit back as Felix Magath's team lost its second straight match.
“We were unfortunate to go down, maybe my players were still trying to deal with the defeat against Bayern,” Magath said. “We came back very well but after 2-2 we again allowed ourselves another letdown. We lacked the desire to win. But we still have a good chance of qualifying for the Champions League.” Schalke captain Heiko Westermann gave away the first goal when he accidentally knocked the ball into his own net with his knee.
“It was an important game, three big points. After getting the 2-2, we shouldn't have lost. We still hope to be in the Champions League next season,” Westermann said.
Ya Konan got his first in the 29th, shooting the ball through the legs of goalkeeper Manuel Neuer, who had needlessly come off his line.
Edu pulled one back in the 46th and Ivan Rakitic converted a penalty in the 52nd to level the score.
But Hanno Balitsch fired a volley into the top corner in the 80th, and Ya Konan rounded Neuer to score again in stoppage time and seal Hannover's victory.
Hannover moved up one place to 16th, which at the end of the season leads to a relegation/promotion playoff with the third-place team from the second division.
Dortmund, unbeaten in five games, was hoping to move into third place with a win in Mainz coupled with Leverkusen's defeat.
But instead, coach Juergen Klopp's return to Mainz, where he had spent 18 years as player and later coach, turned sour when Adam Szalai scored his first Bundesliga goal for Mainz in the 30th minute.
In Bremen, Claudio Pizarro scored twice and had an assist as Werder moved within a point of Dortmund with an emphatic victory over next-to-last Freiburg. Pizarro has 14 goals this season.
Aaron Hunt and Mesut Oezil added goals for Werder.
Cacau came off the bench to score with a deflected shot in the 74th minute for Stuttgart in Berlin. Hertha is now again five points away from the 16th place and is winless at home since opening match of the season.
Cologne deepened Hoffenheim's slump with two goals from Adam Matuschyk, his first in the Bundesliga.
Hoffenheim was the surprise team in its maiden season in the Bundesliga last year but is now six games without a win and angry fans jeered after the match and called for coach Ralf Rangnick to leave.
