Kian Spence's opener was cancelled out by Conor Branson during a first-half in which the hosts squandered some good chances.
Halifax came into the game more after the interval, but it was another subdued display by Town against lower-league opponents, with Halifax well below their best and fortunate to go through against their former boss Billy Heath.
Adam Lund's header was cleared off the line inside the first three minutes, and then Dayle Southwell wasted a big chance after Yusifu Ceesay muscled Tyrell Warren off the ball but Sam Johnson saves his low shot before a follow up effort was cleared off the line by Tom Bradbury.
Highly-rated midfielder Bailey Hobson then side-footed Southwell's cross just over the bar.
Pete Wild went strong in his selection, with only Matty Warburton omitted from arguably Town's strongest available 11.
But The Shaymen were second best.
National League North teams have a habit of making life difficult for Town, and Alfreton were no different - in their faces, moving the ball quickly, scurrying for second balls.
The Shaymen looked sluggish in comparison, making little impact as an attacking force.
But against the run of play, Spence was left with an easy finish after Billy Waters' shot was saved following a delightful through ball by Luke Summerfield, who had been given too much time to pick his pass.
Alfreton hadn't taken their chances, but Town had taken theirs.
However, the hosts only took five minutes to cancel it out and deservedly restore parity when, after a couple of efforts were just about kept out, Branson converted from close range from a set piece.
Town, as usual, tried to play out from the back, but hit a red wall when they reached the final third which they struggled to breach, with Alfreton compact, disciplined and repeatedly picking Halifax off.
And the hosts looked a threat whenever they went forward, with Southwell, one of three ex-Town players starting for Alfreton along with Josh Wilde and Josh Clackstone, regularly bursting down the right and target man Matt Rhead predictably effective in the air at set-pieces.
Spence had seen little of the ball in the number 10 role, Billy Waters looked his usual sharp self but lacked service, with Jamie Allen and Jordan Slew peripheral on the flanks.
By half-time, Alfreton had had 11 shots to Town's one.
After the restart, The Shaymen slowly started to get a foothold in the game, having more sustained possession and controlling the contest better, but Alfreton were still untroubled at the back.
Hobson dragged a shot just wide from Ceesay's pull-back shortly before Warburton was brought on - a complement to Alfreton's defending and an admission that Town needed a spark and some creativity.
The game needed a lift too, having fallen into a lengthy lull, devoid of chances, mired in safety first possession and a lack of cutting edge as the fog descended.
Chris Millington urged Town to take fewer touches and play quicker; it was what Halifax needed but had been entirely absent other than for Spence's goal.
Six minutes of added time seemed a cruelly protracted denouement to what had become a tedious spectacle, with penalties having seemed the only way likely to settle the tie a long time ago. At least now we'd get some shots at goal.
Martin Woods, Niall Maher and Billy Waters all missed in the shoot-out before Jack Senior slid home the decisive kick and the teams were finally prised apart.
Alfreton: Willis, Clackstone (Evans 79), Smith, Wiley, Wilde, Branson, Lund, Hobson, Ceesay (Butterfield 89), Southwell, Rhead. Subs not used: Johnson, Grice, Smith-Eccles.
Scorer: Branson (29)
Shots on target: 8
Shots off target: 8
Halifax: Johnson, Maher, Bradbury, Warren, Senior, Green, Spence (Warburton 66), Summerfield (Woods 76), Slew, Waters, Allen. Subs not used: Benn, Debrah, Swaby-Neavin, Scott.
Scorer: Spence (24)
Shots on target: 1
Shots off target:
Referee: Michael Barlow
Town man of the match: Sam Johnson. Slim pickings from outfield players - has to be the Town keeper for some vital saves. Did what he had to do well, including three penalty saves.