Fabian Balbuena had earlier handed the Hammers a first-half lead, scoring his first goal for the club since his move from Corinthians with a close-range finish.
Their cause was made more difficult in the 38th minute when Mark Noble received a straight red card for raking his studs down Ndidi's calf.
Manuel Pellegrini's side looked like it would withstand Noble's moment of madness, but Ndidi's 89th-minute strike took a significant deflection off Balbuena and spun into Lukasz Fabianski's top corner to ensure a share of the spoils.
Leicester started brightly, Kelechi Iheanacho seeing a strike ruled out for offside after just two minutes, but it was the Hammer who carved out the first effort on target, Kasper Schmeichel keeping out Felipe Anderson's low drive.
Robert Snodgrass flashed wide midway through the half from a tight angle, before Balbuena took advantage of some generous Leicester defending to give the Hammers a 30th-minute lead. The Paraguayan reacted quicker than the sluggish Harry Maguire after his initial header cannoned back off the post and prodded past Schmeichel from close range.
Noble then received his marching orders eight minutes later and the hosts almost immediately made their numerical superiority count, Fabianski repelling Vincente Iborra's header.
The Foxes carved out a host of chances shortly after the hour mark, Marc Albrighton's fierce volley kept out by Fabianski, substitute Jamie Vardy heading over from close range and Maguire thumping his own header against the crossbar.
Leicester looked flat in the closing stages, but Ndidi’s strike from distance took a wicked deflection off Balbuena to prevent his side from slipping to a third consecutive defeat.