Stephen McManus header a winner seven minutes into injury time to give Scotland a 2-1 win at home to minnows Liechtenstein.
Mario Frick's brilliant effort had given Liechtenstein a shock lead, only for Kenny Miller to equalise with a powerful strike.
McManus eventually ensured Scotland grabbed a crucial three points in the pursuit for Euro 2012 qualification.
Scotland created little against the team ranked 141st in the world during the first period, although Kris Boyd headed narrowly wide at the far post from Miller's cross.
Liechtenstein had been venturing into Scotland's half towards the end of the first half, but it was still a huge shock when they took the lead just after the break, as Frick lined up McManus before curling a shot just inside the post.
Scotland's first shot on target came just before the hour-mark, as Darren Fletcher's drive was tipped over the crossbar.
The Scots levelled on 63 minutes through Miller, who fired a fearsome shot in off the crossbar after latching onto a loose ball following a cross from substitute Barry Robson.
David Hasler threatened with a long-range effort at the other end, but Scotland continued to press, although it looked like they would be left embarrassed.
However, the win was achieved when McManus rose highest to power home Robson's corner right at the death.