Richard Marshall’s side edged home in the last 10 minutes, with tries from forwards Elliot Morris and Liam Cooper.
The visitors opened the scoring on 13 minutes when loose-forward Jacob Fairbank rounded full-back Jimmy Watson before giving half-back James Woodburn-Hall a clear run to the try line.
Centre Steve Tyrer kicked the conversion from in front for a 6-0 lead. But with 23 minutes on the clock Hunslet had already forced two drop outs when hooker Jack Lee exploited some sloppy marker defence to score on the final tackle from point-blank range, half-back Reece Dean converted to tie.
What followed was close to an implosion to allow Hunslet to take command. First, Fairbank’s pass on halfway ended up in the hands of Dean, who scurried away to score and convert.
And when a loose long ball from James Saltonstall left Shaun Robinson in all kinds of trouble on his own line, former Fax winger Gareth Potts profited as the half-time score pushed out to 16-6.
Dean’s penalty put Hunslet 18-6 up. But with captain Scott Murrell moving to hooker and Hunslet’s Nathan Chappell in the sin bin, Woodburn-Hall’s kick was pounced on by back rower Ed Barber, Tyrer’s conversion reducing the deficit.
Murrell then put Quentin Laulu-Togagae, who had moved into stand-off, over the line to cut the gap to 18-16.
Momentum swung back Hunslet’s way with a Dean penalty giving them a 20-16 lead in the final quarter but, with 10 minutes remaining, a huge bomb from Reece Chapman-Smith caused havoc , and Morris scooped it up to score.
Tyrer’s kick put Fax ahead at 22-20 with a late try from Cooper, converted by Tyrer putting them on course for a ragged but crucial victory.
Hunslet had the final say through Chappell, but there was no fairytale ending.
Hunslet: Watson, Potts, Chappell, Ashton, Bloomfield, Sanderson, Dean, Jon Luke Kirby, Lee, Robinson, Tonks, Martin, Emmett. Subs: Braham, Hawksworth, Flynn, Halafihi.
Halifax: Laulu-Togagae, Robinson, Tyrer, Saltonstall, Sharp, Murrell, Woodburn-Hall, Kavanagh, Moore, Morris, Barber, Grady, Fairbank. Subs: Fleming, Cooper, Chapman-Smith, Calcott.
Referee: B Pearson.