Dublin were shaken by a spirited second half revival from Donegal who grabbed a goal from Conal Dunne to turn a procession into a match mikdway through the second half.
Tir Chonaill then drew level with eight minutes remaining.
When sub Dara Gallagher made it 1-8 0-11, the momentum seemed to have swung towards Donegal.
Suddenly their awful first-half display when they surrendered possession tamely and ran into cul de saces seemed to have been exorcised as they were lucky to only trail by 0-7 0-1.
But the Dubs dug deep and final points from subs Alan Brogan and Ross McConnell emnsured a narrow but thoroughly deserved victory.
For apart frrom a fifteen minute period in the second half, Dublin outhustled and forced Donegal into repeated costly errors.
Ballyshannon has been a bit of a graveyard for the Dubs in recent years but they were determined to banish the blues.