HUDDERSFIELD GIANTS grabbed two dramatic late tries to snatch an unlikely victory against a Hull side chasing second spot.
Hull had looked certain to move a step closer to their goal, leading 20-10 with less than five minutes remaining.
But Huddersfield's inspirational centre Brandon Costin poached a try from close range on 76 minutes and, moments later, from a superb attack from deep inside their own half, Australian centre James Evans forced his way over out wide to level the scores.
Costin, who announced that he will be leaving Huddersfield at the end of this season, then held his nerve to land an excellent conversion from the left touchline.
The defeat severely dents Hull's hopes of finishing as runners-up to Leeds Rhinos.
They now have to rely on Bradford Bulls slipping up in one of their last three matches if they are to hold on to second place.
And coach Shaun McRae will know that they need to play significantly better if they are to then progress to October's Grand Final at Old Trafford.
Two Paul Cooke penalties had given Hull a 4-0 lead after a disappointing first quarter, before a moment of Stanley Gene magic sparked the game into life.
Huddersfield half-back Gene - playing against his former club - put a speculative long pass out to Julian Bailey, who broke clear from inside his own half. Bailey drew full-back Shaun Briscoe and sent Marcus St Hilaire sprinting to the line.
Costin added the simple extras and stroked over a close-range penalty seven minutes later to give the Giants an 8-4 lead.
But Hull were level by half-time. Gifted field positions by one of seven penalties conceded by the home side in the first half, they moved upfield before Garreth Carvell trampled over three home defenders to score.
Cooke and Costin traded early second-half penalties to make it 10-all, before Jason Smith stepped up with what looked like a crucial intervention.
Aussie loose-forward Smith - sporting a large white bandage on his head as a legacy of his dust-up with Bradford prop Stewart Fielden on Monday - put in a superb 40/20 to take Hull deep into Huddersfield territory.
And on the third tackle of the resulting set, prop Paul King followed in Carvell's footstep by barging over from close range.
Moments later, after Stewart Donlan had fumbled the ball behind his own line, Shayne McMenemy moved the ball to the outstanding Richard Whiting, who dummied his way over in the corner.
That looked to have sealed Hull's win and the Giants were even reduced to 11 men as Paul March and Jim Gannon were sin-binned, along with Hull half-back Richard Horne.
But Huddersfield staged their remarkable late revival to record their first win in eight matches.
HUDDERSFIELD: Reilly, Donlan, Evans, Costin, St Hilaire, Gene, March, Fleary, Penkywicz, Gannon, Smith, Bailey, Jones.
HULL: Briscoe, Best, Whiting, Yeaman, Barnett, Cooke, R Horne, Dowes, Swain, King, McMenemy, Nicholas, Smith.