But the win potentially came at a cost when skipper Billy Sharp limped off in the second half, adding another headache for boss Paul Heckingbottom in a season of injury struggle so far.
United were far from at their best in the first half against Barnsley, who could have gone ahead early on when Matty Wolfe saw an effort well saved by Wes Foderingham.
But the home side went ahead perhaps against the run of play when Sander Berge converted from close range, and Morgan Gibbs-White put the gloss on victory after going around Brad Collins and slotting home after good play from substitute Oli McBurnie.
But the home side went ahead perhaps against the run of play when Sander Berge converted from close range, and Morgan Gibbs-White put the gloss on victory after going around Brad Collins and slotting home after good play from substitute Oli McBurnie.