Christian Benteke had given Paul Lambert's men the lead going into the halftime break, but Jordan Henderson pulled one back before Gerrard's spot kick secured victory.
Christian Benteke had given the Villans a first-half lead. Jordan Henderson equalized immediately after halftime before Gerrard then stepped up, after Luis Suarez had been felled in the box, to convert what would prove the winning spot kick.
Paul Lambert named an unchanged side from the win over QPR last time out while Brendan Rodgers welcomed back Pepe Reina and Jamie Carragher but Daniel Sturridge had to settle for a place on the bench.
Gabriel Agbonlahor squandered a glorious opportunity to give the home side the lead in the 16th minute as he side-footed an effort from just seven yards out straight at Reina after Matthew Lowton had delivered a delicious low cross from the right.
Four minutes later Suarez came close to adding to his 22 league goals this season as he picked up a clever reverse pass from Glen Johnson and smashed high towards goal, forcing Brad Guzan to parry over the top of the bar.
But it was Villa that would take the lead after 32 minutes courtesy of Benteke. Agbonlahor provided the assist for his strike partner as he took down a long pass from Ashley Westwood with his thigh before the Belgian smashed a first-time half volley at goal that Reina could only help into the corner of his net.
Villa was nearly the architect of its own downfall shortly after, though, as Barry Bannan's wayward pass towards his own goal only served to put Suarez through. The Uruguay international was denied by Guzan as he looked to slot his effort through the goalkeeper's legs.
Liverpool again came close to forcing an equalizer before halftime as, in the 43rd minute, Stewart Downing and Philippe Coutinho worked a short corner between them before laying off for Gerrard to send a dipping right-foot shot towards goal that Guzan again did well to push away with his left hand.
The visiting side didn't have to wait long after the break to get back into the game. Two minutes after the restart, Henderson raced onto a delightful through pass from Coutinho before steadying himself and lifting a composed effort over the advancing Guzan and into the net.
Liverpool then came close to taking the lead as Coutinho first struck wide following a clever run across Villa right back Lowton before Johnson struck the post with a bending right-foot effort that flicked off Bannan before rattling the woodwork.
With the next attack, though, the Reds were in front. Suarez, so deadly in and around the 18-yard box, jinked inside Nathan Baker, tempting the young defender into a challenge, and referee Lee Mason had little choice but to point to the spot where Gerrard made no mistake in slotting low to Guzan's right.
Gerrard was then instrumental at the other end as he reacted superbly to head Benteke's powerful header off the line before Lowton had Reina scrambling with a cross-shot that forced the Spaniard to tip over the crossbar.
Benteke did hit the net for a second time in stoppage time although the goal was rightly chalked off for offside and, as the final whistle blew, the result did little to ease Villa's relegation fears, while Liverpool moved to within three points of Merseyside rival Everton.