Scott Grix claimed a second-half brace to give spirited Wakefield a first engage Super League victory at St Helens since 2003.
The Wildcats had lost their previous seven encounters on Merseyside but they dug deep to hold on for a hard-earned and ultimately deserved success, despite being outscored by five tries to four.
Paul Wellens failed to convert any of his side's touchdowns and then missed a last-minute penalty that would have given his side a point as John Kear's men held on admirably.
Saints opened the scoring inside the fourth minute when Ade Gardner plunged over in the right corner to cap a flowing move which saw the ball pass through at least four pairs of hands.
Wellens could not convert the score from the touchline and Wakefield hit back with purpose and vigour.
Danny Brough, a talisman for the Wildcats at scrum-half, asked questions of Saints with a series of probing kicks, yet it was from a mistake that his side drew level in the 10th minute.
Wellens, whose standards have rarely fallen below exemplary, uncharacteristically spilled the ball on the visitors' 30-metre line.
Ryan Atkins was onto it in a flash, collecting possession and showing blistering speed to race from deep inside his own half to outstrip a clutch of Saints defenders and touch down under the posts.
Brough added the easiest of conversions and the pendulum began to swing heavily in Wakefield's favour.
Not even the loss of hooker Tevita Leo Latu - a key figure in the opening exchanges - could halt their early vibrancy.
Prop Ricky Bibey punched holes up front for the Yorkshiremen and Brough and Sam Obst provided a potent threat at half-back.
However, Saints regained the lead against the run of play in the 23rd minute when Leon Pryce collected a short offload from Wellens and burst through a gap to touch down.
Four minutes later, more slick handling from the hosts saw the ball worked out wide towards the left flank where Wellens ushered Dean over the line.
Wellens could not convert either score and he was at fault again in the 31st minute when he allowed the diminutive Obst to weave his way past him and cross the line for a fine individual try which Brough again converted.
Wakefield struck again in the 49th minute when Obst and Brough orchestrated a delightful move which culminated in Grix plunging his way over in the right corner.
The try was awarded after a review from video referee Steve Ganson but Brough could not add the extras from a difficult angle.
Saints, predictably, hit back in the 56th minute when Keiron Cunningham's swift short offload sent the onrushing Francis Meli bustling over from close range.
Yet again Wellens missed the goal and Grix claimed his second moments later - again after review from Ganson - when he squeezed through a gap and Brough added his third conversion.
Dean claimed his second try in the 70th minute when he went over in the left corner but Wellens could not add the extras and then missed a routine penalty in the last minute that would have earned his side a point.