Ironcially, it looked like Mayo were on course to book their place in the play-offs for the fifth time in six seasons when they led by a point heading into injury-time.
But Donegal stuck to their tried-and-tested game-plan, working the ball patiently to one of their designated marksmen, in this case Stephen Griffin.
The substitute duly did the rest, arcing over a superb score from a tight angle near the right corner to earn Donegal the point they needed to leapfrog Mayo in the final standings.
The Westerners were utterly dejected at the final whistle as the realisation dawned that for all their disciplined and organised defending and Trojan effort, 12 wides and yet another lapse in concentration had cost them dearly. Mayo substitute Patrick Durcan also spurned a chance to push his side two points clear in the closing stages, and Donegal made their hosts pay for such profligacy.
“The character we showed was very pleasing, even coming up to half-time; we looked out on our feet,” admitted Donegal manager Rory Gallagher afterwards.
“We had a couple of tough sessions during the week, following on from the game last weekend. That tiredness was in the legs so I was very pleased with the way the lads kept driving at them. They didn’t accept being beaten, hung in, and got the result.
“I’m reasonably happy,” he added. “Number one, we avoided relegation, got a number of competitive performances, and got our key players on the pitch which was what we wanted to do.”
The fact that the game ended in a welter of excitement was in keeping with the rest of a breathless, frantic match that seldom paused for breath and bristled with intent from gun to tape.
Referee David Coldrick was the busiest man in the stadium — and the most unpopular too, judging by the boos from some of the home supporters in the crowd of 12,304 at the end.
He showed 11 cards in total: seven yellow, three black, and a red, the latter coming after Mayo’s Donal Vaughan picked up an early yellow card, allied to a black in the dying moments.
This was the first time the sides had met since then All-Ireland champions Donegal were whipped by Mayo by 16 points in the 2013 All-Ireland quarter-final.
There was an edge to the match throughout, and neither side was prepared to let the other out of their sight.
The scene was set for a grandstand finish by half-time as wind-assisted Donegal went in leading by a point, 1-5 to 0-7.
Mayo midfielder Barry Moran dominated the skies all afternoon, and landed three fine points for good measure.
His early groundwork laid the platform for the locals to lead by 0-4 to 0-2 at the end of the first quarter.
Then a sweeping Donegal move ended with Paddy McBrearty cracking a shot past Kenneth O’Malley, and two quickfire points from Odhrán Mac Niallais saw the visitors surge 1-5 to 0-4 ahead.
Mayo’s response was impressive. A combination of Moran’s fetching and their running game yielded three points without reply as Donal Vaughan and Aidan O’Shea both hit the target.
The second half followed a similar pattern as Barry Moran lofted over the equaliser on 40 minutes before Diarmuid O’Connor potted a beauty to edge Mayo in front.
The home side were still ahead at the end of the third quarter, 0-11 to 1-6, but the fun was only starting. Patrick McBrearty managed to lose Keith Higgins twice to pop over scores in the 57th and 58th minutes that tied the game up for the fourth time.
When Kevin McLoughlin swung over a free on 67 minutes (after an earlier miss), it looked as though Mayo had done enough. Instead, amid all the late scuffles and drama, Donegal’s Stephen Griffin nailed the decisive score.
“You have to look at the positives. I thought we defended very, very well but our shooting is something we need to work on,” remarked Mayo joint manager Pat Holmes afterwards.
B Moran (0-3), K McLoughlin (0-3, 1f), J Doherty (0-2, 2fs), D Vaughan (0-1), A O’Shea (0-1), D O’Connor (0-1), M Conroy (0-1).
P McBrearty (1-3, 1f), O MacNiallais (0-3), M McElhinney (0-1), C McFadden (0-1), S Griffin (0-1).
M Conroy for Ronaldson (HT); S Coen for Harrison (45); A Moran for Kirby (58); M Sweeney for A Moran (63, blood sub); A Moran for Sweeney (65); P Durcan for Boyle (66); N Douglas for McLoughlin (70).
C McGinley for Toye (42); A Thompson for Doherty (42); M McHugh for H McFadden (black card, 48); S Griffin for McGinley (58).
D Coldrick (Meath)