Hull FC remain on target for the play-offs after a desperately hard-fought win over Salford City Reds.
Tries by Tom Lineham (two), Kirk Yeaman and Joe Westerman earned a 12-point first-half lead, Ashley Gibson and Jodie Broughton replying for Salford.
A Sean Gleeson double and a second for Gibson dragged the visitors to within two points, with only the kicking of Jamie Foster keeping Hull ahead.
Jordan Turner's late try sealed the game for the Airlie Birds.
The Reds remain 10th, four points from the play-offs.
The hosts raced into a 12-point lead thanks to 20-year-old rising star Lineham, handed a first start on home turf.
Within six minutes of kick-off, the winger set Hull on their way with a well-taken try before making a 60m break to set up a second score for Yeaman.
The Reds came back through centre Gibson's well-worked try, sparking a period of dominance by the visitors that concluded when Broughton crossed unopposed in the corner to complete a flowing move.
Lineham got Hull back on track with a break which set up field position for Westerman to break the Reds' defensive line and score.
The youngster then completed a half to remember by leaving Broughton flat-footed as he dived over in the corner.
The game became scrappy after the break as Hull extended their lead with a simple penalty kicked by on-loan St Helens winger Foster.
That decision looked wise when Gleeson exploited poor defending to score before Gibson capitalised on Hull ill-discipline to score a second.
Daniel Holdsworth's missed conversion left Salford four points behind, and Hull made that six when another Reds infringement, this time for holding down, allowed Foster to kick a penalty from in front of the posts.
The visitors continued to press and got their rewards when Gleeson touched down by the corner flag, but Holdsworth missed his chance to level the game by hooking his touchline conversion.
With the clock ticking down, ex-Salford player Turner popped up five metres out to take an off-load and seal the points for Hull.
VIEW FROM THE DRESSING ROOM
Hull FC coach Peter Gentle:
"We did our best to throw it away. We got out to 12-point leads twice, but we leaked a bit of pressure and they fought their way back into it.
"It is frustrating because we are looking at the play-offs coming up and, if you get 12 points up in a semi-final, you can't gift sides field position in the way we did.
"On the plus side, it was the first time we've managed to win on the back of a derby game and we did well getting over the physical and emotional fatigue that follows a derby."
Salford coach Phil Veivers:
"I'm very disappointed because we fought back well. The try right on half-time killed us and if we could have held out it may have been a different story.
"It is another one that has got away this year and it is very frustrating.
"The lack of consistency has been the story of our season - it is a subject we have broached many times and it is the area this team needs to improve in."
Hull: T Briscoe; Foster, Turner, Yeaman, Lineham; McGoldrick, Heremaia; Watts, Houghton, O'Meley, Manu, Westerman, Aspinwall.
Replacements: Lynch, Pitts, Green, Nicklas.
Salford: Patten; Broughton, Gleeson, Gibson, Williams; Holdsworth, Sneyd; Jewitt, Howarth, Boyle, Ashurst, Adamson, Wild.
Replacements: Nero, Sidlow, Gledhill, James.
Referee: Robert Hicks (Oldham).