Ayr left it late before condemning a brave Hawick XV to the cruellest of defeats.
Darcy Graham put Hawick in front with a great solo try but this was quickly answered by Djustice Sears-Duru’s short-yards breenge.
Grant Anderson of Ayr and Hawick’s Bruce Campbell then saw yellow after a mass brawl and while it was 14-a-side, Bruce McNeil scored and Hawick led again. But the restored Anderson cut the lead with an unconverted try.
Callum Mackintosh burst through for Hawick’s third try, Kirk Ford converted before adding the extras after another Graham solo effort for Hawick’s bonus point and a 34-13 lead.
Ayr shook themselves awake, Danny McCluskey touched down, Frazier Climo converted before Ayr too clinched their try bonus, courtesy of George Hunter and Craig Gossman tries. Suddenly it was 34-30.
A yellow card for Graham proved costly as Gossman touched down, Climo converted and Ayr led again. But the visitors stormed back and Keith McNeil’s converted try put them 41-37 ahead with ten minutes left.
But in injury time Ayr moved the ball wide and Archie Russell scored the clinching try, converted by Ross Curle.