Dara Costelloe scored in the fourth minute of added time as Accrington came from behind to defeat Gillingham 2-1 in a dramatic ending at Priestfield.
Ben Woods and Costelloe, on loan from Championship club Burnley, both netted in the second half after Armani Little had put Gills ahead shortly after the interval.
Woods saw his deflected shot find a way past September’s League Two Player of the Month Glenn Morris with Costelloe’s late strike finding the opposite corner with a precise finish.
Elliott Nevitt had gone close early on for the Kent side but his header from six yards was comfortably gathered by Billy Crellin.
Accrington grew into the game but were thwarted by an in-form Morris.
Mark Bonner’s side finally made their possession count on 49 minutes when a cross from Remeao Hutton went long and Little was at the back post to smash home an effort into the top corner.
Their lead was shortlived, however, with Woods’ deflected effort finding a way past Morris on the hour mark. The Gills keeper was later replace due to injury.
John Doolan’s men went forward late on and got their rewards when Costelloe’s effort beat Luca Ashby-Hammond.