The England goalkeeper's glaring error enabled skipper Andy King to earn the Foxes a trip to the City of Manchester Stadium on 18 or 19 January.
Hart failed to hold onto an innocuous cross from Paul Gallagher - and King converted the rebound midway through the second half.
Sol Bamba gave Sven-Goran Eriksson's Championship side a first minute lead but James Milner and Carlos Tevez put the visitors in the ascendancy before half-time.
Leicester earned their second chance and were a constant threat from the set-pieces of Gallagher. New signing Bamba troubled Roberto Mancini's side in the air and Hart made some fine saves before his blunder.
City boss Mancini made six changes - with Hart, Kolo Toure, Milner, Tevez and Jo the only survivors from the side which drew at Arsenal in the Premier League in midweek.
New signing Edin Dzeko watched on from the stands. The Bosnian was not signed in time from Wolfsburg to make his debut for Mancini, who had a short spell with the Foxes as a player in 2001.
Leicester boss Eriksson made one change for the clash with his former club with Bamba - a new arrival from Hibernian - replacing Michael Morrison, sold to Sheffield Wednesday, in central defence.
And what an impact the new man made - opening the scoring inside 50 seconds.
Former City striker Darius Vassell won a corner and Gallagher's centre was flicked on at the near post before Bamba applied the finishing touch from close range.
Vassell was causing problems with his pace and earned a free-kick just outside the box when brought down by Adam Johnson.
Lloyd Dyer whipped his cross to the far post and Jack Hobbs parried a header back across goal which Hart was forced to push into the air before collecting at the second attempt.
Foxes goalkeeper Chris Weale then kept out a close-range attempt by Patrick Vieira from Johnson's corner - and the visitors drew level after 23 minutes through Milner.
Tevez's through-ball was perfectly timed for the England midfielder, whose left-footed drive found the right corner of the net.
Tevez shot high and wide from 15 yards but Leicester regained the momentum and Hart made a superb save to turn aside a 25-yard drive from Leicester midfielder Yuki Abe.
From Gallagher's resulting corner, Hart again showed his worth by parrying a close-range header from Bamba, who had another header blocked on the line by Shaun Wright-Phillips.
Johnson should have scored from close range but turned his shot around the post, before Richie Wellens played in King, who failed with his attempt to chip Hart.
Then in the closing seconds of the first half, Tevez put his side in front. Milner supplied a low centre and the Argentinian was alert enough to backheel the ball past Weale.
Leicester began the second half on the offensive and Dyer was sent free of the visitors' defence by Gallagher but he lacked composure and shot wide.
Hart fisted away a header from King, then Hobbs headed over, before Kyle Naughton twice showed good composure to keep Tevez at bay at the other end.
A blunder from Hart enabled King to bring Leicester back on level terms after 64 minutes. Gallagher curled in a centre from the left which bounced just in front of the England international goalkeeper, who failed to collect cleanly. King snapped up the rebound.
Leicester were in the ascendancy and Wellens was brought down right on the edge of the box by Nigel De Jong.
Mancini made what appeared to be a defensive minded switch with Jo replaced by Pablo Zabaleta.
Wellens needed treatment and strapping to his right hand before being able to continue.
Milner came to his side's rescue when he headed Bamba's header off the line
Dyer left the field to a standing ovation when he made way for Martyn Waghorn.
Back came the visitors and Weale made a great save to deny De Jong at close range after he had been teed up by Tevez.
Vassell was replaced by Steve Howard with seven minutes remaining and after Abe shot wide, Weale denied Tevez in injury-time from close range.