French striker Tcham N'Toya-Zoa snatched victory for Chesterfield with the only shot on target in the entire game.
Doncaster should have won the game comfortably after dominating the first half despite playing against a gale force wind.
But they could not find a pay-off punch to match their enterprising approach play and paid the penalty when N'Toya-Zoa struck late in the game.
Rovers were unlucky not to be awarded a penalty in the fourth minute when Gregg Blundell was brought down from behind by Alex Bailey but the referee turned down the appeals.
Doncaster dictated the pace with John Doolan in excellent form in midfield and James Coppinger causing problems with his neat skills on the right flank.
But they could not get the ball in the net and Coppinger had a goalbound shot blocked in the 19th minute before hitting the rebound wide.
Chesterfield barely mounted a first-half attack and when they did manage to venture forward Caleb Folan hit a powerful 20-yard shot over the top.
It was a different story in the second half as Rovers played poorly with the wind at their backs and Chesterfield raised their game.
But the home side were again denied a clear-cut penalty appeal in the 49th minute when Coppinger was brought down by Alan O'Hare.
It looked to be inside the box but the referee awarded a free-kick on the edge of the area and Doolan hammered his shot inches wide of the mark.
Blundell had a shot deflected over the top and Neil Roberts had another effort blocked before Blundell headed over from Coppinger's cross in the 68th minute.
N'Toya-Zoa gave a hint of what was to come when he raced through to fire over the top in the 72nd minute.
But the home side failed to heed the warning and the French striker snatched the points for the visitors with a fine individual goal in the 87th minute, dribbling across the penalty area before slotting home a well-placed shot into the bottom corner.