Two goals of stunning individual quality inspired the Cobblers to their first away win of the season and only a second of 2017 as they picked up three priceless points by beating Gillingham 2-1 at a wind-swept Priestfield on Saturday.
Daniel Powell's terrific first-half effort put Town ahead at the break and after ex-Cobbler Lee Martin dragged Gills level, Matt Grimes scored a wonderful free-kick 17 minutes from time to claim Northampton's third win of the Sky Bet League One campaign and their first in 10 games in all competitions.
The first-half was not one that will live long in the memory as Gillingham shaded a poor affair ruined by the blustery conditions, though Powell will remember it fondly on a personal note as his pile-driver fizzed the Cobblers ahead shortly before the interval.
Martin hauled Gillingham level with a precise finish on the hour-mark but victory went the way of Northampton thanks to Grimes' pinpoint free-kick.
After Tuesday's spirited 2-2 draw against Rochdale, this win was exactly what the Cobblers needed in their bid to reverse their poor form and get away from the bottom four, although for now they remain third from bottom and three points adrift of safety.
There was mixed team news for the Cobblers who suffered the loss of Brendan Moloney to a knee injury before kick-off, meaning Shaun McWilliams started at right-back, but that was offset by the boost of having John-Joe O'Toole among the starting XI for the first time this season.
O'Toole lined up alongside Regan Poole and Grimes in midfield while Sam Hoskins came in for Billy Waters on the right side of a front three.
Grimes sent an early free-kick wide for the visitors but Gillingham made the better start and carved out the first clear opening eight minutes in when Martin, formerly of the Cobblers, whipped in a cross which Jake Hessenthaler glanced beyond the far post.
Powell's low effort was held by Thomas Holy while nifty footwork from Martin led to a shooting opportunity at the other end but Matt Ingram was equal to it, diving full length to palm the ball away from danger.
The swirling conditions caused havoc and made it difficult for either side to play good football, but after Chris Long saw his shot blocked, the Gills had the clearest sight of goal yet when Town failed to clear a corner and the ball dropped to Elliott List, who blasted just wide.
Josh Parker also tried from range after skipping inside and he almost got lucky as Ash Taylor's deflection took it marginally over.
A first-half short on incident and goalmouth activity appeared to be drifting towards half-time when it was brought to life by a moment of brilliance. Grimes fizzed a pass to Powell who did superbly to take it down first-time and, 40 yards from goal, he took a couple of paces forward before unleashing a belting shot that whistled low into the bottom corner, via the inside of the post.
That gave the Cobblers a half-time lead, only the second time that's happened in an away game this season, and they so nearly had a second within five minutes of the restart, only foiled by a fine stop from Holy who kept out Aaron Pierre following O'Toole's flick.
Gillingham were struggling to get going in a frenetic, messy second-half, again affected by the howling wind, but they managed to haule themselves level with a neatly-worked goal just after the hour mark.
Former Town man Martin was the scorer, his shot trickling into the bottom corner having been set through on goal by a clipped ball over the top, before he unwisely celebrated in front of the travelling fans.
Action, if not chances, then came at both ends at the two teams set about finding a second goal, but clear-cut opportunities remained at a premium and it would be another tremendous solo effort that proved decisive.
Long did brilliantly to take down a long ball and win Town a free-kick 25 yards from goal, and Grimes made full use of it, curling a wonderful effort up and over the wall and into the net - off both posts - rendering the stranded Holy helpless.
Northampton now had 17 minutes plus stoppage-time to protect their lead and earn a precious away victory, and predictably it wasn't all plain sailing as Gillingham frantically poured men forward, several times going close most noticeably through Billy Bingham's free-kick that cannoned into the wall.
But, in truth, they created little and the Cobblers deservedly saw out four nervy minutes of stoppage-time to clinch victory.
Gillingham: Holy, Clare, Zakuani, Ehmer, Ogilvie, Hessenthaler, Bingham, Parker, Martin (c), List, Eaves (Garmston 75)
Subs not used: Nelson, Wagstaff, Byrne, Chapman, Cundle, Wilkinson
Cobblers: Ingram, McWilliams, Taylor, Pierre, Buchanan (c), Poole, Grimes, O'Toole (Foley 64), Hoskins (Waters 75), Powell, Long (Richards 89)
Subs not used: Cornell, Smith, Kasim, Bowditch
Referee: Ross Joyce
Cobblers fans: 293