DUBAI, February 2, 2014 (AFP) - Starting the day two strokes clear of the field, the 39-year-old Scot was reeled in by the time he walked off the second green after twice straying off the tee.
But instead of going under, after four bogeys in nine holes, he battled back and, on a day of high drama, emerged in front again on the back nine and held his nerve over the last three holes.
The target of 15 under was set by Argentinian upstart Emiliano Grillo, who sunk a 40-footer for eagle at the par-five last after his over-cooked second outrageously rebounded back onto the green off an hospitality tent.
Wearing black, the same as he did on the final day last year, Gallacher drew level with a birdie at 16 and then a sublime chip from the greenside rough for birdie at the next eased him back ahead.
He needed to par the last to win and he managed that by sinking an edgy three-footer after his third shot had spun back too far to the front edge.
The title defence was something that other former winners such as Tiger Woods, Ernie Els and Seve Ballesteros were unable to accomplish and it revived Gallacher's hopes of playing in the Ryder Cup in Scotland in September.
The new world rankings out on Monday will see him move up to 37th and he is assured of playing in all four majors this year, including his first participation at the Masters in early April.
"It took everything I had after the poor front nine, but I just tried to build on yesterday (63) and stay patient," he said.
"I was quite fortunate that no-one ran away with it and I just tried to hit every shot at a time, just like yesterday.
"I knew a five (at the last) was going to win it and it's the only time that I've hit a back spin like that all week and it's nearly gone in the water.
"But yesterday was the key - to be 10 under through 10 holes.
"I wish I could play this course every week."
Grillo was solo in second for the biggest prize of his fledging career so far with France's Romain Wattel and Brooks Koepka of the United States a further stroke back on 14 under after a 66 and 70 respectively.
Tournament favourite Rory McIlroy endured a torrid final day and could only manage a 74 and a tie for ninth.
The Irishman was steady enough to start with, parring the first six holes, but a bogey at the next appeared to suck the confidence out of him and three bogeys in four holes after the turn ended his challenge.
"It was just one of those days," he said.
"I think anything that sort of could go wrong did. Okay I hit a couple of loose drives, but I didn't really get away with them or stuff like that. Just sort of, you know, one of those days."
World number three Henrik Stenson closed with a 68, but could do no better than tie for 29th.
Woods, meanwhile, finished with a flourish, birdieing his final three holes for a closing 71.
But he was already, at the start of the day, too far behind to have any say in the proceedings as he left Dubai tied for 41st and still looking to kick his 2014 season into full gear.
"Unfortunately I turned it around too late," he commented.
Leading final scores on Sunday in the $2.5 million (1.85million euros) Dubai Desert Classic, part of the European PGA Tour:-
Majlis Course, par-72
272 - Stephen Gallacher (SCO) 66-71-63-72
273 - Emiliano Grillo (ARG) 71-67-69-66
274 - Romain Wattel (FRA) 68-73-67-66, Brooks Koepka (USA) 69-75-70-70
275 - Mikko Illonen (FIN) 69-72-70-64, Robert Rock (ENG) 69-70-68-70, Steve Webster (ENG) 71-70-64-70, Thorbjorn Olesen (DEN) 71-68-65-71
276 - Paul Casey (ENG) 70-72-67-67, Bernd Wiesberger (GER) 70-70-68-68, Edoardo Molinari (ITA) 65-72-68-71, Rory McIlroy (NIR) 63-70-69-74
277 - Brett Rumford (AUS) 69-70-71-67, Thomas Bjorn (DEN) 72-70-68-67, Francesco Molinari (ITA) 69-69-71-68, Danny Willett (ENG) 71-65-73-68, Soren Hansen (DEN) 67-71-71-68, Paul Waring (ENG) 70-70-68-69, Darren Fichardt (RSA) 69-72-66-70
278 - Simon Dyson (ENG) 69-69-73-67, Damien McGrane (IRL) 66-70-71-71, Jamie Donaldson (WAL) 69-68-70-71