A game with an abundance of passion and pride failed to deliver many goalmouth incidents and seemed more likely to be remembered for the failure of referee Mike Dean to send off Everton's Ross Barkley in the second half.
The midfielder was shown only yellow for a violent stamp that struck Jordan Henderson above his ankle.
But deep in injury time, Daniel Sturridge cut inside and saw his well-aimed shot strike the foot of the right-hand post, rebounding into the six-yard area where Mane reacted first and converted the game's only goal.
That dramatic goal allowed Liverpool to move to within six points of league leaders Chelsea, with Manchester City a further point back in third. Everton, with just one win in seven, are ninth.
"It's a wonderful feeling," purred Klopp in his press conference. "Really, really good. It was a long, long stoppage time. We gave them no chances. We deserved to win."
His Everton counterpart Ronald Koeman, who was experiencing his first Merseyside derby, disagreed.
"The substitutes of Liverpool had a big impact in the final result," Koeman told the media. "We didn't keep the ball after the break so much. The team didn't deserve to lose the game."
However, Koeman conceded Barkley was fortunate to stay on the pitch. "Barkley, maybe he was lucky. Maybe it's a red," said Koeman, who in his heyday as a player was renowned for his physicality.
Without a derby win in the last six years, and with just one victory from the last 19 fixtures with Liverpool, Everton had started the game in impressive and aggressive fashion but lost their way after the interval.
After 22 minutes, Barkley - the only native Merseysider on either side - pushed the ball wide to Aaron Lennon whose cross forced Ragnar Klavan into an important interception with Romelu Lukaku poised to connect at the far post.
Then moments later, another Everton attack ended with Leighton Baines setting Barkley away for a 25-yard shot which passed within feet of the post.
Everton were unsettled at the interval by the loss of the injured midfielder James McCarthy, who made way for veteran Gareth Barry, and Liverpool finally began to make an impression on proceedings.
On 50 minutes, the visitors carved out the best chance of the game with James Milner's long pass seeing Firmino shrug off Funes Mori and advance clean through only for Stekelenburg to deny him with a brave block.
Lukaku eased the pressure, momentarily, when he headed just over while twisting, off-balance, to meet Barry's pass but it was only a brief respite as Mane exchanged passes with Firmino on 57 minutes and was denied by the combined efforts of Leighton Baines and Stekelenburg.
That incident proved costly for the Everton goalkeeper who could play on for only another seven minutes before being forced off with a leg injury, handing the gloves to substitute Joel Robles.
Barkley was fortunate only to be shown that yellow card in that 67th-minute incident, which angered Lovren and saw players briefly square up to each other - a flashpoint which also led to a booking for Everton's Seamus Coleman.
The visitors continued to enjoy the better of the closing stages with Robles making the save of the match, diving quickly to his left to keep out Firmino's volley on his line before the goal, and Coleman having to clear a Firmino shot off the line in the sixth of eight minutes added on.
A hard-fought but very welcome win for Liverpool who now sit in second place above Man City and Arsenal on 37 points, 6 behind runaway leaders Chelsea going into Christmas.