The game had entered four minutes of stoppage time and penalties were looming when substitute Ahmed Elmohamedy sent over a superb cross for Trezeguet to drill a far-post finish across Leicester keeper Kasper Schmeichel.
It sparked wild scenes of joy and a pitch invasion at Villa Park, as the hosts reached their first showpiece final since the FA Cup in 2015, when they lost 4-0 to Arsenal.
Villa – who face either Manchester City or Manchester United in the final – were indebted to goalkeeper Orjan Nyland for a string of magnificent first-half saves that allowed them to go in at the interval leading through Matt Targett’s 12th-minute strike.
And the hosts were enjoying their best spell of the game when Kelechi Iheanacho turned in Harvey Barnes’ cross with 18 minutes left, leaving the momentum with Brendan Rodgers’ side.
But Trezeguet’s late intervention means Dean Smith’s side will be in their first EFL Cup final since 2010, when they lost to Manchester United.
Nyland and Grealish Villa’s heroes
Villa had two standout performers on this glory night as the hosts produced a finale that left Leicester with no chance of a comeback in the dying seconds of a thunderous encounter.
Nyland formed a one-man barrier against a barrage of Leicester attacks as the Foxes went for the kill in the first half.
The 29-year-old Norwegian produced an astonishing string of saves, particularly two low down from James Maddison and arguably the best of all when he touched Youri Tielemans’ rising drive on to the bar.
It kept Villa in contention and protecting that precious lead given to them by Targett, allowing Grealish to exert his own influence both as a creator and someone who could hold the ball in moments of stress.
Grealish should have set up a debut goal for £10m striker Mbwana Samatta, who somehow failed to even get a touch on his cross from six yards out with the goal at his mercy.
Samatta, who was substituted, will have been a relieved man when Trezeguet produced that decisive finish and Villa were on their way back to Wembley, a place they last sampled when they beat Derby County in the Championship play-offs last season.