Barnsley snatched their third win in a row when Adam Hammill slammed home from a tight angle in the second half to inflict Doncaster's first home defeat of the season.
Hammill's 74th minute decider came completely against the run of play after Doncaster had dominated a pulsating South Yorkshire derby clash.
But the injury-hit home side could not find the finishing touch to match their enterprising approach work and the Tykes continued their march up the table following the arrival of Mark Robins as manager.
Barnsley began brightly with Steve Foster and Darren Moore both having shots blocked following an early corner.
But it was all Doncaster after that as they laid siege to the visitors goal without success.
A splendid move involving James Coppinger and James Chambers led to James Hayter having an angled effort cleared off the line in the eighth minute.
On loan striker Billy Sharpe fired home a minute later only to be ruled offside and then Sam Hird had another effort cleared off the line in the 15th minute.
Barnsley defended tenaciously but they had keeper Luke Steele to thank in the 19th minute when he pulled off a magnificent one-handed save to tip Coppinger's looping header over the bar.
Steele distinguished himself again on the stroke of half-time when he did well to hang on to a cracking effort from Martin Woods with both Sharp and Hayter ready to pounce.
The second half followed the same pattern and Dean Shiels was out of luck when he hit the crossbar in the 54th minute, before Coppinger and Sharp had shots saved in quick succession.
Sheils was only inches off the mark again in the 60th minute and Woods hammered a free-kick fractionally wide six minutes later, before Coppinger dribbled through to fire just off the mark.
Barnsley's only second-half opportunity came in the 69th minute when Hammill had a tame effort easily saved.
But the 21-year-old former England youth international made amends in the 74th minute when he scored from an impossible looking angle after firing home at the near post following a corner from Iain Hume.
It was heart-breaking for Doncaster but Barnsley defended solidly for the rest of the match to take the points.