A first half goal from Diogo Jota was enough for Jurgen Klopp's side to take a narrow lead into the break.
The Reds dominated the second half, but had to wait until the closing stages for Jota to add a second thanks to an inspired performance from Kasper Schmeichel.
The result closes the gap between Liverpool and Manchester City to nine points, with the Reds having a game in hand on the leaders.
Leicester remain 12th and without a win in four games in all competitions.
Story of the game
It was almost a perfect start for the Reds, after just 15 seconds Trent Alexander-Arnold switched the ball to Luis Diaz, who tried to cut in and fire at goal. However, Daniel Amartey stood his ground well to tackle the Colombian.
New signing Diaz looked well up for his Premier League debut in the early stages, showing good tenacity when out of possession.
Leicester’s first chance of the game came on the counterattack, when a loose ball from Alexander-Arnold was pounced on by James Maddison.
The Foxes threat in behind was evident, with Patson Daka almost through on goal soon after.
After 20 minutes, TAA found the ball at his feet on the right-hand side of the box, he fooled two Leicester defenders as he cut onto his left foot and fired a venomous effort at Kasper Schmeichel’s goal. But the Dane did well to tip the shot over the bar.
The Reds were inches away from taking the lead a few minutes later, as Alexander-Arnold’s cross was almost headed home by Andrew Robertson at the back post. But the cross just evaded the Scot.
After 34 minutes the home side got the goal that they were craving. An Alexander-Arnold outswinger was attacked fiercely by Virgil Van Dijk and Schmeichel did well to save the initial effort.
However, his parry dropped straight to Jota who reacted sharply to fire home from five yards - the Portuguese wingers 11th league goal of the season.
Five minutes before half time, the sight of Mohamed Salah warming up lit up the Anfield crowd momentarily, as the Liverpool faithful were glad to see him back available again.
A minute later, a good cross from Robertson was punched out to the edge of the area by the Leicester goalkeeper, but only to Thiago, whose brilliant acrobatic effort looked goal bound before bouncing just wide of the post.
On the stroke of half time, some exceptional one and two touch passing saw Roberto Firmino through on goal inside the area. But the Brazilian’s left footed effort was stopped by the Danish no 1.
Five minutes into the second half Firmino received the first booking of the match when he made a desperate attempt to challenge Kiernan Dewsbury-Hall, who looked like threatening the LFC backline.
Some good play between Diaz and Robertson down the left-hand side led to the latter firing a low effort at the away sides goal, but Schmeichel got down well to push the ball out.
On the hour mark, Anfield erupted as if the Reds had scored a second, but it was instead the introduction of their main man Salah after a month away at the Africa Cup of Nations.
With 67 minutes gone, Diaz pounced onto a loose touch from a Leicester defender and slid Jota through on goal, but Amartey managed to do enough again to deny an effort.
A couple of minutes later Jota found Diaz who attacked Amartey and shifted the ball onto his left foot, however his shot could only blaze wide of the Foxes goal.
With 15 minutes to go, it looked like there might be another vintage Salah goal. Some neat footwork in a tight space saw the Egyptian beat two Leicester defenders before shooting straight at Schmeichel from a tight angle.
Moments later a mistake in the Leicester ranks saw Salah go through on goal, but a brilliant save by the Foxes keeper was enough to keep his side in the match. There was a brief VAR check for a penalty after some contact, but nothing was given.
Liverpool then began to turn it on, Salah struck a bending left footed effort that bounced back off the woodwork, and Diaz hit a thunderous half volley that was pushed away again by the busy Leicester shot stopper.
With less than ten minutes to go, a good pick out from Salah saw Diaz bear down on goal in the box, a poor first touch forced the winger a little wide, but he still managed a strong effort at the Leicester goal. Yet again, Schmeichel came to his side’s rescue.
The final chance of the game was a Salah snapshot, but a goal on his return wasn't to be. A comfortable Anfield night in the end for Klopp's men.