Scarborough turned in their best performance of the season by some way and led 15-12 on 80 minutes in a superb derby with Bridlington at Silver Royd.
However they conceded an injury-time try which saw the men from Dukes Park burgle a narrow win following a rousing game.
Bridlington took an early first half lead when they scored a converted try from close range in the eighth minute.
In front of a large and vocal home support Scarborough came straight back and were rewarded by a try from number eight Isaac Faamau converted by fly-half Tom Harrison to level at 7-7.
Faamau was in the thick of things when a break from deep in home territory saw the big number eight release lock Phil Watson who scored in the corner to see the Seasiders lead 12-7 at the break.
A penalty from centre Graham Hogg stretched the Scarborough lead to 15-7 on the hour but the visitors struck back with a try three minutes later to cut the lead to 15-12.
A punishing fourth quarter battle for both sides saw Hogg miss with another couple of penalties which could have stretched the Scarborough lead before that late unconverted try broke Scarborough hearts.