Christian Benteke’s 80th-minute goal for Villa, a weak shot that crept beneath David de Gea, set up an uncomfortable finale for United, but Herrera completed his brace in added time to seal a fifth straight win.
The result lifted United above City, who visit Crystal Palace on Monday, and with Rooney netting in memorable fashion, Louis van Gaal’s side seem increasingly likely to claim a place in next season’s Champions League.
United felt they should have been handed an early opportunity to take control of the contest when they had a strong penalty appeal waved away after only four minutes.
As Rooney looked to latch onto Marouane Fellaini’s flick, he appeared to be held back by Ciaran Clark, but referee Roger East waved play on.
It was a decision that infuriated the England captain and his mood almost darkened a minute later when De Gea failed to deal with Benteke’s header and Gabriel Agbonlahor saw a goal-bound follow-up blocked.
It was the start of an entertaining game, as Juan Mata saw a shot blocked by Matt Lowton after an exciting run from ex-Villa winger Ashley Young, who was the target of constant abuse from his former supporters.
Villa remained a counter-attacking threat, via the pace of front pair Benteke and Agbonlahor, but such was United’s dominance in terms of possession that even defender Marcos Rojo threatened.
Twenty-three minutes in, the Argentina defender unleashed a fearsome 30-yard shot that Brad Guzan tipped acrobatically over his crossbar.
Michael Carrick — fresh from rave reviews following England’s 1-1 draw against Italy in mid-week — started a move that culminated in Antonio Valencia crossing for Rooney to lash a spectacular overhead kick just wide.
– De Gea blunder –
Two minutes before the break, a rare lapse in defensive concentration from Villa’s back four allowed Young to free Daley Blind on the left and his pull-back found the unmarked Herrera 15 yards from goal.
The Spanish midfielder had the time and presence of mind to set himself before sending an unstoppable finish into the bottom-right corner with his left foot.
Rooney and Rojo both had chances to add to the score before the half-time whistle, after sharp thinking by Mata and Blind at a quickly taken corner, but Clark and Guzan, respectively, were able to block.
There was a warning for United soon after the restart as Villa strung together a lightning-quick counter-attack that resulted in Andreas Weimann cutting the ball back for Benteke, who blazed wastefully over from 10 yards.
But the home side responded quickly as Mata’s cross-field pass was gathered by Young, who cut in from the left and placed a curling right-foot shot fractionally wide.
United clearly recognised the need for a second goal and Fellaini almost delivered it with a strong downward header that the alert Guzan pawed over the bar.
Rooney maintained the pressure, sprinting into the area and firing narrowly wide of the left-hand post, before Fellaini shot the wrong side of the same upright with an improvised back-heel.
Moments after a Villa set-piece ended with Benteke heading just wide, Rooney claimed United’s second.
Substitute Angel di Maria’s cross was behind Rooney, but the England man showed superb footwork to bring the ball down, swivel and hook it into the top-left corner with his trusty right foot.
The two-goal cushion lasted barely a minute, with De Gea uncharacteristically allowing Benteke’s tame shot to slip beneath him, but Herrera’s assured finish from Mata’s pass settled the home fans’ nerves.