Jean-Claude Darcheville came off the substitute's bench to rescue Rangers in a turgid affair at Inverness Caledonian Thistle.
In a first half that could best be described as insipid, far too many misplaced passes meant both goalkeepers had very little to do.
The first shot in anger arrived 15 minutes in when Daniel Cousin used his ample frame to bundle his way to the edge of the box, but his wayward shot caused little concern to Caley Thistle number one Mike Fraser.
Ten minutes later and it was the turn of the home side to threaten, Richard Hastings playing in Markus Paatelainen only for the Finn to be denied from close range by Allan McGregor in the Rangers goal.
At the other end Caley Thistle were defending stoutly and good pressure by Grant Munro on Cousin meant the Frenchman could not get any sufficient power behind a Chris Burke cross on 28 minutes to trouble Fraser, who saved easily.
The opening 45 minutes looked to be meandering to a close after this, but there was still time for Steven Whittaker to force Fraser into a fine block at his near post after being picked out by Steven Naismith.
The fare after the interval was not much better, although at least Rangers manager Walter Smith was trying to alter the course of the match as he introduced Darcheville for Naismith.
But it was midfielder Charlie Adam who thought he had put the visitors in front after 71 minutes with a curling shot that found the corner of the goal, only for the linesman to rule it out for offside against Cousin.
Moments later, Caley Thistle brought on veteran winger Barry Wilson and he came close to setting up Marius Niculae, but his shot from the edge of the box failed to really test McGregor.
A fierce 25-yard drive that struck the top of the crossbar by Adam seven minutes from time appeared to suggest that it was not going to be Rangers' day, yet they snatched all three points in the 89th minute.
Inverness were punished for failing to clear their lines as a long, hopeful ball was collected by Darcheville and he poked his shot past Fraser for the winner, despite the home side appealing for offside.
Even then, Caley Thistle did have one final chance to earn a share of the points in stoppage time, but, from ten yards, Ross Tokely blasted his effort high and wide.