Alexis Mac Allister scored a 97th-minute winner as Liverpool beat Nottingham Forest in a chaotic finish at the City Ground.
The Argentinian, who moments earlier had had a goal disallowed for handball, bundled the ball into the net from close range in front of thousands of delirious Liverpool fans.
Those supporters then had a second nervy wait but Virgil van Dijk, whose downward header was saved by Stefan Ortega before Mac Allister tucked in the rebound, was ruled onside.
This time his celebrations could continue after his earlier one was cut short when the video assistant referee had intervened.
Ortega had made a great save to deny Hugo Ekitike and as Ola Aina tried to clear the ball, his clearance hit Mac Allister’s and flew into the net. But the fortuitous goal was chalked off because the ball was deemed to have hit his elbow.
It was a high-octane finish to a match which had been largely devoid of goalmouth action.
Liverpool, who worryingly lost Florian Wirtz in the warm-up, were uninspiring for long periods but the victory moves them to 45 points, lvel with fourth-placed Chelsea and Manchester United in fifth.
Forest, buoyed on from their midweek European win over Fenerbahce, were arguably the better side and under Vitor Pereira, they are already showing encouraging signs.
Pereira kept faith with the starting XI that won in Turkey three days ago and they dominated the first half but failed to take their chances, with Callum Hudson-Odoi denied early on by a great save from Alisson.
Liverpool, who had more than a week to prepare for this game, were woeful in the opening 45 minutes. Arne Slot’s side managed just three touches in the Forest box, while the 12 shots they faced in the first half was the most since their 6-1 defeat at Stoke in 2015.
The visitors did improve after the break with Curtis Jones’ effort kept out by Ortega but until added time, that was Liverpool’s only attempt on target.
Forest came close too in the second half with Nikola Milenkovic heading wide. Pereira changed his entire frontline in the hunt for a winner but it was Liverpool who snatched it late on.
Forest remain 17th, two points clear of West Ham, who are 18th.
Liverpool analysis: Slot’s side pull off a heist
Liverpool were the lucky ones in a game of fine margins – Slot
For most of the opening period Liverpool struggled to get out of their own half. The late blow to Wirtz certainly didn’t help as Liverpool’s rotten injury luck continued but the absence of one player should not have such a seismic impact.
In came Jones for Wirtz, with Szoboszlai starting at right-back but it took just half an hour for Slot to switch the pair around. Liverpool have had their struggles this season and this display was among the worst.
“In your head, Arne, Arne Arne” was the chant from the Forest fans in reference to Slot’s failure to beat Forest before today but by full time, that was the chant from the travelling supporters after their side pulled off a heist.
Liverpool have hardly been short of late drama this season, conceding four winners after the 90th minute and Mac Allister’s goal wasn’t even their latest goal of the season. Rio Ngumoha’s 100th-minute winner at Newcastle holds that record.
And Ngumoha deserves credit in this win after he was introduced for Mohamed Salah, who now hasn’t scored in his past nine Premier League games.
Ngumoha looked lively and probed down the right, putting in the dangerous cross that eventually led to Mac Allister’s disallowed goal.
Forest analysis: Pereira ‘angry with football’
Before Forest’s win against Fenerbahce on Thursday, Pereira told his players to “express themselves”. It worked in Istanbul and the way they started against Liverpool, you got the sense that his team talk would have been very similar.
His side raced out of the blocks and were it not for a fantastic save from Alisson to deny Hudson-Odoi, they would have taken an early lead.
In midfield, Ibrahima Sangare and Elliott Anderson ran the game while they were hardly tested defensively until the latter stages.
This was a defeat that will certainly sting given the manner of it but there were encouraging signs for Forest.
They might be only two points above the relegation zone but on the basis of this showing, they should have enough to stay up.
“I am frustrated inside,” said Pereira. “I am angry with football, but you know, it’s time to keep the mentality, to come back stronger and with confidence to face the future. The first half we played in the way that we played in Istanbul but we didn’t score the goals.”
What’s next for both teams?
Nottingham Forest welcome Fenerbahce in the second leg of their Europa League play-off on Thursday, 26 February (20:00 GMT) before they travel to Brighton on Sunday (14:00).
Liverpool host West Ham at Anfield next Saturday (15:00 GMT).