Walsall launched a smash-and-grab raid to claim all three points from the penalty spot just four minutes from time.
But it was a controversial winner as the referee overruled his linesman to award a spot-kick which Lee Bradbury converted. Derby defender Michael Johnson
was also sent off for the foul which led to the penalty.
Both sides carved out plenty of chances between them in the opening 45 minutes at Pride Park, but as the game wore on it was the home side who looked the more likely winners.
The visitors created the first clear opening after four minutes when Zigor Aranalde's cross found Jorge Leitao, but he sent his close-range header wide.
Darren Bazeley then saw his shot saved by Derby goalkeeper Lee Grant as Walsall continued to press. Paul Merson tried his luck from distance, but was off target.
Walsall keeper James Walker had to be on his toes to deal with Paul Peschisolido's sharply-struck shot after 10 minutes.
But, with the game opening up, Walker's opposite number Grant parried an effort from Leitao shortly afterwards.
Walker then pulled off a fine save as Derby's Leon Osman tested him from 20 yards midway through the half.
Derby began to gain the upper hand as the half wore on with Manuel Manel having his fiercely-struck effort blocked by Ian Roper on the half hour.
Derby were forced to replace the injured Paul Boertein with Rob Edwards, but they started the second half strongly.
And they almost gained the breakthrough 10 minutes after the interval, only for Walker to keep out Osman's close-range volley.
Walsall has yet another narrow escape just three minutes later when Manel headed over from Candido Costa's cross as the home side threatened to take control.
Costa was replaced by Marco Reich after 64 minutes as Derby continued to push for the opener.
Shortly after his introduction Reich had a shot blocked by Neil Emblen as Walsall struggled to get out of their own half.
Walker was again the hero for Walsall with an excellent save from Tom Huddlestone's piledriver after 70 minutes.
With the home side continuing to push for a winner Ian Taylor saw his mis-hit effort drift wide nine minutes from time.
They were left to count the cost as Walsall snatched the points from the penalty spot four minutes from time.
Johnson and Bradbury were challenging for the ball when the linesman flagged for a foul.
Initially the linesman appeared to have given the free-kick to Derby but the referee overruled that and awarded a penalty which Bradbury crashed home in off the post.
Walsall almost added another as substitute Jermaine McSporran rattled the woodwork shortly afterwards.
Derby staged a grandstand finish but were unable to force an equaliser despite over five minutes of injury time.
Teams
Derby Grant, Kenna, Mawene, Johnson, Boertien (Edwards 45),
Costa (Reich 64), Taylor, Huddlestone, Osman,
Peschisolido (Junior 79), Manel.
Subs Not Used: Oakes, Bolder.
Sent Off: Johnson (85).
Walsall Walker, Bazeley, Emblen, Roper, Aranalde, Osborn,
Burley, Merson (Wright 90), Andrews, Leitao (McSporran 69),
Bradbury.
Subs Not Used: Petterson, Carbon, Kris Taylor.
Booked: Andrews, Roper, Walker.
Goals: Bradbury 86 pen.
Att: 23,574
Ref: M Jones (Cheshire).