Carlos Augusto and Lautaro Martinez scored in the second half to lift the league leaders three points above second-placed Napoli and six points above third-placed Atalanta.
Napoli had earlier been held 0-0 at relegation-threatened Venezia.
The fight for the final Champions League spot is also tight, with just six points separating six teams in the race for fourth place after more misery for Juventus, who lost 3-0 at Fiorentina.
It was a head-to-head clash for top spot in Bergamo, with Atalanta knowing that victory would move them level on points with Inter and Napoli.
Both sides had great chances in an entertaining first half, with Inter going closest with less than seven minutes on the clock.
Inter broke the deadlock in the 54th minute, immediately after play resumed following a delay of several minutes as a fan got medical treatment in the stands.
A corner was whipped in from the right and Augusto rose relatively unmarked to head into the bottom left corner.
It was only his third goal for Inter in two seasons at the club.
Atalanta's chances of getting back into the match diminished nine minutes from time. Ederson was booked for dissent and then sarcastically applauded the referee, who showed the Atalanta midfielder a second yellow card and then a red.
Lautaro sealed the match six minutes later. Atalanta coach Gian Piero Gasperini was still protesting the Ederson decision and he was also sent off.
Inter defender Alessandro Bastoni was also sent off following a second yellow card.
Juventus coach Thiago Motta is under even more pressure after his team slipped out of the top four, shipping seven goals in two matches and scoring none.
Robin Gosens and Rolando Mandragora scored within two minutes of each other in the first half and Albert Gudmundsson added another after the break as Fiorentina moved to within five points of the top four.
Juve's season was already in tatters after a dismal 4-0 loss at home to Atalanta last weekend. The Bianconeri had also been eliminated from the Champions League and Italian Cup.
Motta's former team, Bologna, replaced Juventus in fourth after an impressive 5-0 drubbing of sixth-placed Lazio.
Seventh-placed Roma beat Cagliari 1-0.