Chris Westwood returned to haunt Wrexham with a last-gasp knock-out blow in a frenetic Boxing Day clash at the Racecourse.
After a dour first half the game exploded into life when Mark Carrington (64) netted less than a minute after Neil Ashton saw his penalty saved.
Goals from Michael Wylde (73) and Job Ayo Akinde (85) turned the tide in Alfreton’s favour, before Leon Clowes (87) looked to have rescued a point.
However, Westwood, who converted one of Wrexham’s penalties in the FA Trophy triumph at Wembley in March, had the final say when he netted in the fifth and final minute of added time after the ball was played back in from another ex-Red, Darran Kempson.
Wrexham, blighted by a raft of suspensions and injuries to several mainstays of the first team, began brightly with Rob Evans and Johnny Hunt having shots saved by Jon Worsnop in the Alfreton goal.
However, their early pressure almost went to waste when Akinde sprung the offside trap, only to fire tamely wide with just Andy Coughlin to beat.
Carrington found the roof of the net with an angled drive from distance after 21 minutes, before Worsnop saved at the feet of Evans after Alfreton failed to deal with Joe Anyinsah’s low drilled centre across goal.
As the game opened up Coughlin was relieved to see a Danny Meadows effort fizz just inches the other side of the post, after Alfreton’s slick counter-attack down the right almost paid dividends.
Leon Clowes got his bearings wrong when heading wide from Carrington’s piercing delivery, as Wrexham struggled to make a notable impact on the game.
After a timid start to the second half Brett Ormerod thought he had finally broken the deadlock, but his superb volley from 18 yards was clawed away by Worsnop for a corner.
Just after the hour, the Wrexham die-hards finally witnessed some drama, as referee Ben Toner spotted a handball by Akinde and pointed to the spot.
Skipper Ashton drove his penalty low to Worsnop’s left but the impressive keeper was equal to the task with a superb stop.
However, Alfreton failed to clear their lines and Carrington capped a man-of-the-match display with a fine low drive into the corner of the net from 12 yards.
Instead of building on their lead Wrexham were pegged back less than ten minutes later. Disarray in the Reds defence led to an Alfreton corner and Tom Shaw’s whipped delivery was expertly headed past Coughlin by Wylde.
Substitute Jay Colbeck volleyed into Worsnop’s arms before Akinde made a goal out of nothing, smashing a shot into the net from distance with Coughlin berating himself for not doing better.
Two minutes later Wrexham stemmed the flow of home fans heading for the exits early. Clowes’ bullet header from Hunt’s cross gave Worsnop no chance to set up a frenetic finish.
A draw looked to be on the cards before Westwood had the last laugh on his former team-mates with the decisive header with just seconds remaining.
Wrexham: Coughlin, Tomassen, Clowes, Artell, Ashton; Carrington, Evans (Colbeck, 78), Hunt; Anyinsah, Ormerod (Morrell, 84), Ogleby (Bailey-Jones, 90+3).
Subs: Mayebi, Parle.
Alfreton Town: Jon Worsnop, Bradley Wood, Lathaniel Rowe-Turner, Darran Kempson, Chris Westwood, Michael Wylde, Dan Bradley, Daniel Meadows, John McGrath (Tom Shaw 46’), Job Ayo Akinde, Paul Clayton (Daniel Wishart 72).
Subs: Ross Atkins, Alistair Taylor, Jay McFadzean.
Referee: Ben Toner Lancs)
Alfreton: Wylde (90, foul)