Rangers maintained their four-point lead in the Scottish Premiership after Scott Arfield's goal earned what manager Giovanni van Bronkhorst called a "big" win over Livingston.
For 75 minutes at Ibrox, the champions looked set to drop points for the second game in a row and concede more ground to closest challengers Celtic.But Arfield came off the bench to earn a nervy victory.
"We kept fighting to win the game, which we did," said Van Bronckhorst.
"I am very proud because it was a very difficult game, very difficult circumstances. If you see the chances we had in the first half, not so much the second half, but we don't score, it is going to be difficult."
The win extended Rangers' unbeaten run in all competitions to 21.
It was just Livingston's second defeat in seven games. And, although they remain ninth, both Dundee and bottom-club St Johnstone edged a point closer to them in the battle to avoid relegation.
It was a big night for 18-year-old Alex Lowry, given his first start for Rangers after scoring from the bench on his debut in the 4-0 Scottish Cup romp over Stirling Albion.
And the teenager impressed, being at the centre of everything Rangers threw at Livingston in the first half.
He had the champions' first chance of the match as Fashion Sakala teed him up on the edge of the box, but he shot straight at goalkeeper Max Stryjek.
Then Lowry picked out Scott Wright, whose goalbound shot beat the goalkeeper, but not Jack Fitzwater who had raced back to clear off the line.
Twice the twinkled-toed Lowry collected the ball out wide and drove neat balls across the face of goal from both wings, but each time no-one in blue could take advantage.
Livingston were giving a good account of themselves. Fitzwater met a corner with a downward header, but Allan McGregor saved it on the line. The visiting players raced to the referee to appeal for handball, but Don Robertson ignored their claims.
And Stryjek had to pull off a fantastic save at the other end to deny the home side when James Tavernier's driven cross found Sakala at the front post, and the Polish goalkeeper got his legs to the ball to deflect it over the bar.
Sakala became the main man after the break as he took the game by the scruff of the neck, but he was struggling to add the end product to his play.
A good turn and shot led to an easy save for Stryjek, then a driving run forward was followed by a shot that was always rising over the bar.
But Arfield eased Ibrox nerves when he finally broke the deadlock. Borna Barisic exchanged passes with Sakala, and chipped a ball to the veteran midfielder, who hooked it over the defence and into the far corner.
Ayo Obileye had a late chance for Livingston but couldn't connect with a looping ball into the box as Rangers held on.
The forward put in a hard-working shift for Rangers and was always looking to make something happen
January is proving to be a tough month for Rangers, and after dropping points at Aberdeen they nearly squandered more against Livingston as they struggled to cut the visitors open.
But the performance of teenager Lowry will be one of the talking points among the support. The gifted midfielder went looking for the ball from the first whistle and was at the centre of much of their good play. He had a quieter second half but still showed flashes of what he could do.
Livingston will be frustrated not to have left with a point. A Fitzwater header apart they didn't create too many chances, but the performances of Obileye and Stephane Omeonga in particular were positives.
Rangers manager Giovanni van Bronckhorst: "I'm very proud because it was a difficult game, very difficult circumstances. I'm happy with the substitutes - Scott Arfield hadn't played for a while but he came on and he changed the game."
Livingston manager David Martindale: "Did we deserve to come away with three points? Probably not. Were we a wee bit unlucky not to get a point? We probably were.
"I let the fact [Ianis] Hagi, [Alfredo] Morelos, [Ryan] Kent and [Joe] Aribo were out of the Rangers team come into my thinking and I went a bit more adventurous. I don't think we caused Rangers too many problems but our goalkeeper wasn't that busy."
Rangers are away to Ross County in the Scottish Premiership on Saturday (12:30 GMT), while Livingston are at Hibernian later that day (15:00).