Hamburg secured a potentially priceless 3-1 victory at fellow strugglers Wolfsburg to improve their chances of remaining in the Bundesliga next season.
Goals from Bobby Wood and Lewis Holtby shortly before half-time sent Hamburg on their way to a third win in four games, with Gian-Luca Waldschmidt adding a late third.
Wolfsburg replied through Josip Brekalo, but will join their opponents in the bottom three on Sunday should Mainz avoid defeat against RB Leipzig.
The Wolves had failed to score in five of their last six Bundesliga games and Divock Origi fired their first chance wide after six minutes after a jinking run into the penalty area.
At the other end Wood fired over, before the United States international saw another attempt saved by Koen Casteels.
Wolfsburg lost defender Marcel Tisserand to injury after 12 minutes, with Riechedly Bazoer replacing him, while in attack Renato Steffen sent Paul Verhaegh's pass over the bar.
Wood saw a volley deflected away and a header sail over either side of Gideon Jung's header being hacked behind for a corner as the visitors began to impose themselves.
And they went ahead after 42 minutes when Josuha Guilavogui conceded a penalty with a rash challenge and Wood beat Casteels from the spot.
Holtby doubled Hamburg's advantage in first-half stoppage time, the former Tottenham forward heading home Tatsuya Ito's cross.
Wolfsburg pressed after the break as they sought a way back into the game, but Origi was crowded out on 64 minutes and Maximilian Arnold blazed wide two minutes later.
Guilavogui fired wide from the edge of the box with 20 minutes remaining as the hosts continued to dominate, but at the other end Filip Kostic should have put the game to bed only to fail to get enough power on his shot to beat Casteels.
Casteels saved well from Wood, but with 12 minutes left Brekalo set up an exciting finish by firing in a free-kick.
Bakery Jatta missed two late chances for Hamburg and Kostic saw a stoppage-time penalty saved before Waldschmidt converted the rebound to seal a result that takes them to within two points of safety with two games remaining.