- Oops!Something went wrong.Please try again later.
Germany have gone within minutes of being knocked out of Euro 2020 before a late equaliser from Leon Goretzka saved their blushes against Hungary.
Goretzka salvaged a 2-2 draw for Germany on Wednesday night in a whip-saw contest that sets the Germans up for a June 29 match against England at Wembley.
'WHAT A DISGRACE': Uproar over 'disgusting' moment at Euro 2020
Hungary looked like they would shock Germany and send them out of the tournament after Adam Szalai's diving header in the 11th minute opened the scoring.
Kai Havertz drew Germany level in the 66th minute but Hungary retook the lead seconds after the re-start when András Schäfer ran past the defenders and headed the ball into the net.
But with coach Joachim Loew throwing on substitutes to gain the point needed to progess to the last 16, Goretzka's strike provided Germany with the late life-line.
Leading 2-1, Hungary were on the verge of an extraordinary advancement to the knockout stages.
But it wasn't to be, with football fans around the world expressing their disbelief on social media.
Germany finished second in the group with four points and will next face England at Wembley Stadium on Tuesday.
In the group's final match, Portugal drew 2-2 with France to ensure both progress, while Hungary finished last with two points and are eliminated.
Sweden send Poland home in 3-2 thriller
Earlier, Sweden winger Emil Forsberg scored twice - including the second fastest strike in European Championship history - before Viktor Claesson's stoppage-time goal helped them seal a 3-2 win over Poland to top Group E.
It was a heartbreaking end to Poland's campaign on Wednesday after they twice drew level through a double from talismanic skipper Robert Lewandowski, whose 84th minute equaliser for 2-2 gave them a glimmer of hope.
Sweden's previous two matches were built on robust defensive displays that had cast doubts on whether Janne Andersson's side could get their attack firing, but they made a blistering start through the lively Forsberg.
After Robin Quaison controlled the ball on the edge of the penalty area, Forsberg collected a pass and took advantage of some poor defending to fire past goalkeeper Wojciech Szczesny with 82 seconds on the clock.
He doubled their lead with a powerful drive for his third goal of the tournament after substitute Dejan Kulusevski weaved his way into the box to lay it on a platter in the 59th minute.
Lewandowski pulled a goal back two minutes later with a curling shot before Jakub Swierczok's tap-in from substitute Przemyslaw Frankowski's pass was ruled out for offside after the Video Assiatant Referee's intervention.
Lewandowski, who missed chances to make it 1-1 in the first half after rising above Sweden's defence only to thunder two headers onto the crossbar, fired in the equaliser from close range after a pass from Frankowski.
But Sweden were not done yet, as Kulusevski slipped the ball to Claesson who slotted past Szczesny to secure the win.
"It was a rollercoaster, emotionally. It was 2-0 and as calm as it could be, then they got back into the game and got two goals," Claesson told Sweden's TV4.
And Spain crushed a hapless Slovakia 5-0 for their first win, setting up a last-16 clash against Croatia after being set on their way by a calamitous own-goal from keeper Martin Dubravka.
Aymeric Laporte headed in a second goal on the stroke of half-time before second-half goals from Sarabia, Ferran Torres and a Juraj Kucka own goal rounded off an emphatic win on Wednesday that saw them finish second in Group E on five points behind Sweden.
Watch 'Mind Games', the new series from Yahoo Sport Australia exploring the often brutal mental toil elite athletes go through in pursuit of greatness:
Click here to sign up to our newsletter for all the latest and breaking stories from Australia and around the world.