Hull FC overcame a poor start to record victory against Wakefield and end their three-game run without a win.
Jamie Shaul scored two tries on his Hull debut, leading the Airlie Birds fightback after Peter Fox and Danny Kirmond gave Wakefield the lead.
Ben Crooks added to his first-half score with a second after Shaul and Aaron Heremaia tries, with Lee Smith replying for the Wildcats.
Tom Briscoe crossed for Hull before Dean Collis' late consolation.
Danny Tickle kicked five goals for Peter Gentle's Hull side, while Paul Sykes landed three for Wakefield.
Defeat will have disappointed Richard Agar, coming against his former club and on the back of a hard-earned victory against Castleford on Friday, but it was hugely welcomed in West Hull, where derby defeat by Rovers and three games without a win have seen pre-season optimism evaporate.
Tryscorer Heremaia did not make the best of starts to the game on his return to the side, dropping the ball to hand Wakefield possession and then catching Kirmond high for a set that Fox finished off in the corner.
England call-up Ben Cockayne fed second rower Kirmond, who burst clean through to touch down for the second soon after, but Hull fought back when Shaul slipped a string of white shirts to run in his first try.
Kiwi pivot Heremaia then offloaded for Crooks to score, before Sykes' penalty ensured parity at the break.
Shaul crossed shortly after the interval to restore Hull's lead, and Smith responded for Wakefield after a team move.
However Gentle's Black and Whites took the game by the scruff of the neck when Heremaia picked the gap to go over and then found Crooks for his brace.
Briscoe's score put Hull out of sight and Collis' unopposed finish was too little too late for the hosts, who have now lost four of their last six.
VIEW FROM THE DRESSING ROOM
Wakefield Trinity Wildcats head coach Richard Agar said:
"I think we looked a little bit tired and flat at times. We started the game okay but we went through periods of looking a little bit tired, which was surprising. It wasn't an overly fast-paced game and it was a very stop-start affair.
"The over-riding feeling is that we've beaten ourselves and gifted too many points to them in what probably should have been a tight game, the way both teams were playing.
"We've handed too many opportunities on a plate for them that they didn't really have to earn that much."
Hull FC head coach Peter Gentle said:
"We've all worked hard for it. We're disappointed from the other day. Hopefully this helps appease our fans to a certain degree, it won't replace won't happened the other day but the significance of losing the derby wasn't lost on us.
"I'm not relieved, just proud. We have been lacking a little of self-belief, I think you saw that grew as the game went on.
"We've been guilty of playing not to lose and we spoke about playing to win and the confidence grew on the back of a very good kicking game in the second half and you saw us evolve as a team there this afternoon."
Wakefield: Mathers, Fox, Collis, Lyne, Cockayne, Sykes, T. Smith, Poore, Aiton, Wilkes, Lauitiiti, Kirmond, Washbrook.
Replacements: L. Smith, Raleigh, Amor, Annakin.
Hull: Shaul, Lineham, Arundel, Crooks, Briscoe, Horne, Heremaia, Watts, Houghton, Lynch, Galea, Tickle, Westerman.
Replacements: O'Meley, Whiting, Johnson, Crookes.
Referee: James Child (Dewsbury)