Centre Tuoyo Egodo – recalled in place of Greg Minikin – was Castleford’s hero, scoring the crucial try against Wigan Warriors six minutes from time, after Tigers had trailed 20-0 inside 22.
Tigers wiped out a 16-point deficit in their previous game at Leeds Rhinos only to be beaten in golden-point extra-time and it looked like there may be more heartbreak when Wigan regained the lead with 16 minutes left.
But they then had a touchdown ruled out by the video referee and, after James Clare had gone close, Egodo nipped over from acting-half to move the hosts back in front.
As the hooter sounded, Wigan attempted a miracle play near their own line, the ball went loose and Peter Mata’utia touched down, also adding his fourth conversion to seal a remarkable 38-28 victory.
Egodo and his right-side partner Clare had been tormented in the first half as Wigan built a seemingly unassailable lead, but it was the centre’s tackle which jarred the ball loose from George Williams at the start of the second period which turned the tide.
Within minutes Tigers had gone from 16 points down to two ahead. Mitch Clark, returning from injury, pulled a try back seven minutes after the break, and two later Matt Cook marked an outstanding display in his 100th Castleford appearance with a touchdown, both going over from close-range off passes by Adam Milner.
Milner, standing in at hooker for the suspended Paul McShane, went over from acting-half to edge Cas ahead, but Wigan regained the lead when Joe Burgess crossed from Jake Shorrocks’ pass.
Moments later Dan Sarginson had a touchdown ruled out by video official James Child – after referee Chris Kendall had signalled a try – and that decision was to prove crucial.,
Injury- and suspension-hit Tigers fielded only one specialist half-back, Mata’utia moving up from full-back to partner Jake Trueman.
That was evened up when Wigan lost scrum-half Jarrod Sammut to injury, attempting to tackle Calum Turner who came in as the last line of defence. Wigan also lost opening try scorer Joe Greenwood and Dom Manfredi after the break.
Greenwood opened the scoring on 11 minutes and Oliver Gildart went over three later; then in the next set turned provider by breaking clear from deep inside Wigan territory and Williams was in support to complete a brilliant long-range touchdown.
Sammut’s clever pass allowed Gildart to send Burgess through, but after Sammut’s departure Oliver Holmes showed tremendous strength to twist over and pull an unconverted try back.
Though Gildart went in for a soft score from acting-half three minutes before the break, Tigers grabbed a lifeline with a lovely score on the final play of the half when Mata’utia’s disguised pass fooled the defence and sent Turner racing through a gap, though again he could not add the extras.
To the delight of the home fans, Zak Hardaker – on his first return to his former club –managed to convert only two of Wigan’s six tries.
Tigers suffered another injury blow losing Nathan Massey with collarbone damage.
Castleford Tigers: Turner, Clare, Egodo, Shenton, Eden, Mata’utia, Trueman, Watts, Milner, Millington, Holmes, Sene-Lefao, Massey. Subs Cook, Clark, Maher, O’Neill.
Wigan Warriors: Hardaker, Manfredi. Sarginson, Gildart, Burgess, Williams, Sammut, Bullock, Leuluai, Navarrete, Isa, Greenwood, Partington. Subs Byrne, Shorrocks, Smithies, Tautai.
Referee: Chris Kendall (Huddersfield).