The Nerazzurri have lost six of their last 10 games and seen their hopes of securing a Champions League place dwindle.
Their European campaign had also ended in the last 16 of the Champions League at the hands of Marseille.
Youth team coach Andrea Stramaccioni will take temporary charge of the team after Ranieri's departure, and will become the club's third manager of the season and the fifth since Jose Mourinho left for Real Madrid after the treble-winning 2009/10 season.
"President Massimo Moratti and Inter Milan thank Claudio Ranieri and his staff for their professionalism, dedication and sincerity in recent months at the helm," a club statement read.
"We wish the largest and most affectionate good luck to Andrea Stramaccioni," it added.
Stramaccioni has recently guided Inter's youngsters to glory in the first edition of the NextGen series, a European football club cup competition for under-19s.