Italy missed a glorious chance to end a three-year wait for a Six Nations win as Greig Laidlaw's late penalty secured Scotland a hard-fought 29-27 triumph in Rome.
Tommaso Allan – who had represented Scotland at junior level – scored 22 points, including two tries, as the Azzurri looked set to end a 16-match losing run in the tournament.
However, having led 24-12 early in the second half at the Stadio Olimpico, the hosts faded badly down the stretch to suffer yet more disappointment.
Scotland capitalised on Italy's tiredness, tries from Sean Maitland and Stuart Hogg, both converted by Laidlaw, putting them 26-24 ahead as the game moved towards a climax.
Allan slotted over a penalty to briefly put Italy back ahead, only for Laidlaw to respond with a successful kick of his own in the 79th minute that finally settled a see-saw contest in Scotland's favour.
The win means Gregor Townsend's squad finish the campaign with three victories and two defeats, as they did in 2017.
After Allan kicked Italy ahead with a seventh-minute penalty, hooker Fraser Brown had the simple task of picking up Hamish Watson's long pass and falling over the line for Scotland's opening try.
However, Italy responded to the setback by scoring 14 points in the space of seven minutes.
Allan beautifully stepped off his right foot to reach the line himself before setting up Matteo Minozzi with a clever grubber kick that the full-back gleefully gathered under pressure.
Scotland's riposte was prompt and powerful. Benefiting from a rolling maul, captain John Barclay plunged over for a try that Laidlaw successfully converted, making it 17-12 at the break.
Despite seeing a try from Sebastian Negri ruled out for a knock-on, Italy extended their advantage when Jake Polledri's powerful run set up a second score for Allan, who also added the extras to make it a 12-point cushion.
Yet the clock, as well as a back-line reshuffle, worked against Italy, as they succumbed in the closing stages to suffer a fourth Six Nations whitewash in the last five years.
Switched to fly-half after Finn Russell was forced off through injury, Laidlaw provided the pass for Maitland to glide over before Hogg left Negri grasping at thin air to get the bonus-point try.
Allan's boot briefly gave the home fans renewed hope, only for Laidlaw to hold his nerve from a tight angle, his successful kick completing the comeback and condemning Italy captain Sergio Parisse to a 100th Test defeat.
SCOTLAND WIN!!!!!!!!!!!!!!!!!!— J.K. Rowling (@jk_rowling) March 17, 2018
And I need a defibrillator.
Key Opta Stats:
- This was just the third win for Scotland in their last 20 Six Nations games away from home, all three of those victories coming in Rome.
- Italy have now lost their last 17 games in the Championship, the joint longest such run in Five/Six Nations history, level with France who lost 17 from 1911 to 1920.
- Parisse won his 65th cap, drawing level with Brian O’Driscoll as the most capped player in Five/Six Nations history. However, he also became the first player in history to lose 100 Test matches.
|Golden Boot winner Kane aims to break August hoodoo|
|NFL training camp 2018: Contract holdouts and where they stand|
|Guardiola took me to another level - Alaba|
|Madrid selling Ronaldo a ´historic error´ - Calderon|
|MLS Review: LAFC, Atlanta held at home|
|Stones will watch re-runs of England´s World Cup matches|
|Ferdinand challenges Mourinho to unleash Pogba at United|
|Mbappe: I´m staying at PSG|
|Former NHL goalie Ray Emery found dead|
|Pirates secure five-game sweep of Brewers with walk-off win|
|WATCH: LeBron receives standing ovation at Lakers´ summer league game|
|Tony Romo wins celebrity-filled American Century Championship|
|McGregor praises Putin after attending World Cup final|
|Open-bound Kim claims maiden title with eight-shot triumph|
|Eagles running back Sproles plans to retire after next season|
|World Cup winner Rami retires from international football|
|Wimbledon champion Djokovic did not expect grand slam glory so soon|
|Ibrahimovic praises Pogba after World Cup final display|
|Wimbledon diary: Avengers too late for an Infinity War as Djokovic triumphs|
|Deschamp-agne – France´s 2018 vintage interrupt news conference to drench coach|
|I may have to dust my boots off! - Pele threatened by Mbappe exploits|
|WATCH: Mendy and Pogba dab with president Macron after World Cup win|
|Woods embracing ´different´ Carnoustie challenge ahead of Open return|
|Argentina dismiss Sampaoli after chaotic World Cup|
|France celebrates World Cup triumph|
|Djokovic made ´improvised Wimbledon trophies´ as a boy|
|Stone goes agonisingly close to 59 as Pepperell & Dantorp also make Open|
|Outcast Benzema delights in France win|
|Final a triumph in itself given Croatia´s off-field turmoil|
|Anderson laments Wimbledon final nerves|
|Deschamps joins elite club, Mbappe second to Pele - the best stats from the World Cup final|
|Belgium´s Courtois wins World Cup Golden Glove|
|Collarbone fracture confirmed for ´devastated´ Porte|
|World Cup final player ratings: Griezmann, Mbappe inspire France as Croatia fall short|
|World Cup winner Giroud ends tournament without shot on target|
|Modric wins World Cup Golden Ball|
|Mbappe wins World Cup Young Player award|
|Deschamps redeemed as France win World Cup final for the ages|
|France 4 Croatia 2: Twitter Report|
|Tomlin optimistic over Bell contract|
|Kane wins World Cup Golden Boot|
|Ajax keen on Blind deal - Van der Sar|
|France 4 Croatia 2: Pogba and Mbappe seal thrilling World Cup triumph|
|Anderson would have played another 21 hours to reach Wimbledon final|
|Djokovic delighted to crown ´comeback´ with Wimbledon glory|
|World Cup final interrupted by pitch invaders - Pussy Riot claim responsibility|
|Djokovic´s grass-court U-turn pays ultimate dividends with Wimbledon title|
|Mandzukic makes World Cup history with early own goal|
|Dominant Djokovic beats Anderson to regain Wimbledon title|
|Everybody said I´m done - Degenkolb revels in first Tour victory|
|´Big party´ for Marquez after Sachsenring success|
|Hazard enjoys Belgium´s welcome home|
|Ex-AC Milan president Berlusconi conflicted over Ronaldo to Juventus|
|Spain did not contact Martinez over head coach vacancy|
|Maybe the VAR was watching The Simpsons! - RSL coach Petke slams MLS officials|
|Cubs´ Darvish hopes to return by next weekend|
|France and Croatia name unchanged sides for World Cup final|
|Marquez maintains Sachsenring dominance|
|Courtois claims World Cup has boosted his value|
|Buffon beaten on difficult PSG debut|
|Vince called up for Headingley decider|
|Farah inspires Tigers win over Dragons, Warriors and Roosters triumph|
|Crash forces Porte out of Tour for second year running|
|Ronaldo considered Napoli move, says De Laurentiis|
|Mafi arrested for allegedly assaulting Rebels team-mate|
|Everybody is welcome - Croatia pitch for neutral support in World Cup final|
|West Ham seal club-record swoop for Felipe Anderson|
|Rooney applauds England for capturing fans´ imagination|
|Krajicek urges Anderson to go for broke in Wimbledon final|
|Wimbledon 2018: Djokovic v Anderson in Opta numbers|