Filip Benkovic's first senior goal in England came on his first league start

Nahki Wells and Filip Benkovic scored their first goals for Bristol City as the promotion hopefuls survived a Derby County fightback to earn a thrilling fifth win in six Championship games.

The Robins lacked urgency in a shaky opening 30 minutes as the Rams dominated possession and played with the assurance of a team who were also eyeing the play-offs following a run of five victories from seven.

But Wells marked his full debut with a composed close-range header to settle a nervy Ashton Gate crowd.

On-loan Leicester City defender Benkovic bravely headed in number two on the follow-up after the visitors had blocked a header from Famara Diedhiou, who then struck to make it 3-0 after the break.

Martyn Waghorn's stylish diving header from Max Lowe's delightful cross brought hope for the Rams and Chris Martin tucked in a second, but City held on for a precious victory.

They are just outside the play-off spots as sixth-placed Preston won at Stoke, but Lee Johnson's team are only three points behind second-placed Leeds in a congested Championship table.

Derby, who could have moved to within four points of the top six had they won and results elsewhere gone in their favour, were the better side early on with influential captain Wayne Rooney finding plenty of space in midfield.

But aside from a sharp Duane Holmes strike that was well blocked by keeper Daniel Bentley after a slick move and fine pass by Max Bird, they were unable to create any decent chances.

City, well beaten by Birmingham City in their previous home match, slowly regained their confidence and began to pose an aerial threat, Diedhiou and Benkovic both heading over before they took the lead with the best move of the match.

The full-backs were the creators, with good skills by Jack Hunt on the right ending with a floated cross which Jay Dasilva volleyed back into the box first time for new signing Wells to head home from six yards - the forward's 14th league goal of the season.

Niclas Eliasson's set-piece excellence then helped the hosts romp into a three-goal lead, with an inviting corner leading to Benkovic powering in number two and also teeing up the third for Diedhiou with a cute ball into the box just before the hour.

Waghorn replied within three minutes and, with the Rams beginning to seize control again, they were convinced they should have had a penalty when Ashley Williams appeared to block a cross with his arm.

An exquisite clipped Rooney pass into the box then almost found Tom Lawrence before the second away goal came courtesy of Martin's close-range effort from Lawrence's cross from the left.

There were still eight minutes remaining, plus four minutes of injury time, but it was the hosts who should have scored goal of a pulsating match, only for Diedhiou to dink an effort wide when one-on-one with Ben Hamer in the final moments.

Bristol City head coach Lee Johnson told BBC Radio Bristol:

"We've got to celebrate that win like it's a last minute winner because the effort it takes to go 3-0 up is going to leave a few heavy legs when we've got three debutants.

"It felt tense because they had a lot of possession but between the goal there wasn't a lot of action.

"We've got to put the game to bed, either taking it into the corner at the end or taking one of those chances and then everyone's enjoying the win."

Derby boss Phillip Cocu:

"We controlled the game for long periods and lost because of set-pieces. We have to be better at marking and stopping crosses. We are scoring more away from home, so it is very frustrating to lose to goals like we conceded tonight.

"I thought in every other respect we played a very good game. To come back from three goals down is never easy, but we almost did it.

"The players were sure we should have had a penalty for handball in the second half, but it was difficult to see from my position. And why there were only four minutes of stoppage time I can't imagine."