A goal in either half from Darren Bent and Will Hughes put Derby County in to the next round of the FA Cup - but it was far from comfortable against Chesterfield.
The Spireites gave their supporters plenty to shout about with a determined display from the first to the last whistle against their Championship opponents.
Paul Cook’s Blues were far from second best in the fourth round tie but were undone by a lapse of concentration from a set piece that allowed the Rams in.
A couple of superb stops by Tommy Lee when left one-on-one with ex-England international, Bent, kept Chesterfield in the game before Hughes killed it late on.
The visitors to the iPro Stadium shaded possession and racked up more attempts on goal than Derby - 19 to 13 - but couldn’t find a way through the hosts’ defence.
There was just the one change to the Chesterfield eleven that took to the field seven days previously at Swindon Town - Jay O’Shea in for the injured Gary Roberts.
The Spireites were welcomed on to the iPro playing surface by a vocal away following from close to 6,000 fans who had made the journey down from north Derbyshire.
Chesterfield settled quickly and saw plenty of the ball early on, moving Derby’s three-man defence from side to side and forced a couple of openings for Armand Gnanduillet.
His first came after good play by Eoin Doyle on the right side of the area, he crossed to the back post where Gnanduillet saw his effort blocked at point blank range by Richard Keogh.
The Rams’ skipper misjudged a cross field ball to present the striker with another sight of goal, Gnanduillet brought the ball down and tried to find the corner but it was easy for Kelle Roos.
Sam Clucas found space just outside the area, moved the ball to Doyle who decided not to shoot and instead attempted a nutmeg on Raul Albentosa but was unsuccessful.
The Spireites were dominant in midfield but Hughes showed the quality he possesses when he side-stepped Jimmy Ryan and played a one-two with Chris Martin but was crowded out by Gnanduillet tracking back.
Instead, it was Derby who were showing signs of nerves, keeper Roos slicing a simple back pass in to touch and later in the half spilling a Jay O’Shea strike, quickly having to recover to avoid embarrassment.
But, against the run of play, Derby went ahead from their first corner of the game, Jake Buxton nodding down and Bent sneaking in at the back post to head the hosts in front on 20 minutes.
Chesterfield responded by getting their foot on the ball and O’Shea went within a whisker of bringing the visitors level with a thunderous drive from 20 yards that flew past Roos and his left hand post.
The Spireites were comfortable on the ball and played their way out of a trouble more than once. Clucas couldn’t keep his shot down after Ryan’s pull back from the byline in their only notable other chance of the first half.
Derby were restricted to very few clear chances but Chesterfield hearts were in mouths when Bent got the wrong side of Sam Hird, only for the defender to just do enough to put the ex-England man off as he headed wide.
Steve McClaren felt a change was needed at half-time, as he brought Johnny Russell on for Raul Albentosa, and switched to a 4-4-2 formation. Spireites moved to a 4-2-3-1 with Doyle moving out wide on the right.
Lee was far from convincing when coming for a Omar Mascarell floated free-kick in to the box but kept his side in it with two fine saves when left one-on-one with Bent.
Bent sprung the offside trap and looked to shift the ball on to his favoured right foot but was quickly closed down by the Chesterfield keeper, who spread himself to make the stop.
The visitors flooded forward looking for a response. Clucas dribbled in to the hosts’ penalty area before a last-ditched Buxton challenge stopped his progress, O’Shea picked up the loose ball but saw his goalbound effort deflected over.
Tendayi Darikwa came to the Spireites’ rescue to clear a shot from Russell off the line, after the winger had sped clear of the defence. He was later replaced by Jamie Ward after picking up a knock.
Doyle created a chance for himself when he latched on to Gnanduillet’s flick, sold Buxton the dummy but took an extra touch to steady and flashed a shot wide of Roos’ goal.
A defensive error from Charlie Raglan allowed Bent in, who looked to loft the ball over Lee only for the keeper to get more than finger tips to keep his side in it as the game became stretched.
Ryan blazed over at the other end after Dan Jones’ run to the byline had picked him out at the back post, and substitute Simon Dawkins rattled the cross bar for the hosts after Jamie Ward’s cross.
Dan Gardner and Ollie Banks gave the Spireites another gear, breaking at speed to frustrate the home crowd who began to grow tired of their side’s apparent lack of urgency on the ball in defence.
Chesterfield were quick in to the tackle but so was Hughes for Derby’s second, who pounced on Clucas’ heavy touch on his own 18-yard box and hold off the challenge of Sam Morsy to put the hosts in to the next round.
Derby County (3-5-2): Roos, Christie, Forsyth, Buxton, Keogh, Hendrick, Martin (Dawkins 68), Hughes, Mascarell, Albentosa (Russell HT, Ward 64), Bent. Subs not used: Bryson, Shotton, Mitchell, Warnock.
Chesterfield (4-4-2): Lee, Darikwa, Hird, Raglan, Jones, O’Shea (Gardner 75), Morsy, Ryan (Banks 75), Clucas, Doyle, Gnanduillet (Dieseruvwe 86). Subs not used: Wright, Humphreys, Evatt, Talbot.
Goals: Bent 20, Hughes 80 (Derby); None (Chesterfield).
Bookings: Hughes 57, Christie 80, Hendrick 90 (Derby); None (Chesterfield)
Referee: David Webb (Lancashire)