Christian Eriksen ensured Tottenham's bid to reach the Champions League knockout stages will go to the final group game after the Dane secured a late 1-0 win over Inter Milan at Wembley.
Spurs, who endured a terrible start to their Group B campaign, were heading out of the competition as they were frustrated by a disruptive Inter side until Eriksen climbed off the bench to slam home an 80th-minute winner.
They are still outsiders to progress, however, and they will have to produce one of the most famous nights in the club's history if they want to do it, as they have go to group winners Barcelona in a fortnight and match the result of Inter, who play at home to PSV Eindhoven.
Although they were made to work hard by the Italian side, who came to do a job knowing a point would seal their qualification, they deserved the win as Harry Winks earlier hit the crossbar and Jan Vertonghen somehow headed wide from close range.
Given the critical nature of Tottenham's predicament, it was little surprise they dominated and they should have been awarded an early penalty when Lucas Moura was barged over by Matteo Politano.
Harry Kane started the game like a man on a mission and a brilliant run from the halfway line opened up space for Dele Alli, but the England international drilled his 20-yard shot over.
Inter came into the game for a period without threatening and Spurs, led by a rampant Moussa Sissoko, got back on top.
The Frenchman created a good chance for Lucas when he robbed the opposition of the ball in the right-back position and then broke at speed, squaring for the Brazilian, who shot too close to Samir Handanovic.
Their best moment of the first half came eight minutes before the interval when they worked it neatly to Winks, whose dipping effort from 25 yards thundered into the crossbar.
The frustration levels increased after the break as Inter did everything to disrupt the game and Spurs had no fluency whatsoever.
Chances were harder to come by, but when they did they were decent ones.
First Alli, who boss Mauricio Pochettino hailed as a big-game player before the game, skewed a good opportunity wide from the edge of the area before Vertonghen nodded wide from just a couple of yards.
Inter did threaten on the break as Ivan Perisic brought a fine save out of Hugo Lloris, but Spurs' golden moment came with 10 minutes remaining and it was a brilliant goal.
Serge Aurier passed to the marauding Sissoko, who burst into the area and fed Alli, whose superb tee-up put it on a plate for Eriksen to smash home from 10 yards.
There was a nervy ending as a 1-0 win meant Spurs had the better head-to-head record and Inter pressed for an equaliser, with Lloris producing a smart save to deny Danilo D'Ambrosio.
They saw it out, though, and head to the Nou Camp with their fate in their own hands.