David McGoldrick struck late as relegation-threatened Ipswich won only their third game of 2013 at the expense of play-off hopefuls Leicester.
McGoldrick, on loan from Nottingham Forest, punished defender Wes Morgan's lapse in concentration to score from 12 yards five minutes from time.
Leicester striker Harry Kane had earlier fired wide from Luke Chambers's poor backpass.
The Foxes also went close when full-back Paul Konchesky fired just over.
Ipswich are now six points clear of the relegation zone while Leicester remain in the play-off places in fifth, although seventh-placed Middlesbrough's win over leaders Cardiff means the Teessiders are now only three points behind the Foxes.
Kane had the first chance of any note midway through the first half, but his effort did not threaten the Town goal and when the forward tried his luck again just before the half-hour mark he could only fire wide from 10 yards.
Konchesky them struck an effort over the bar, before Kasper Schmeichel made good saves to deny Chambers and McGoldrick at the other end.
Leicester's Danish keeper was called into action again straight after the break, again saving from McGoldrick.
But it was the Foxes who should have opened the scoring when Chambers's mistake put Kane clean through, only for the loan signing from Spurs to send his effort wide.
Leicester were punished for their wastefulness with a few minutes remaining, when McGoldrick finally beat the defence with a well-taken winner.
Ipswich Town boss Mick McCarthy:
"I'm delighted, relieved and glad it's over. It was a well-organised, gutsy performance.
"We weren't the best team by any stretch of the imagination but when it was required we had that little bit of brilliance of composure from David McGoldrick.
"It was a good, aggressive game. You'd expect that from Mick McCarthy and Nigel Pearson teams."
Leicester boss Nigel Pearson:
"We weren't at our best but still had enough chances to get something out of the game, although other off-the-ball incidents contributed to the result.
"All you have to do is take a look at them. I'm not a sour grapes person. He [Wes Morgan] got booked for complaining about somebody elbowing him in the face. Everyone could see that. [Michael] Chopra kicked him off the ball just prior to that.
"All in all it was a bit of a scrappy game but we had chances and didn't take then. We didn't deserve to lose but credit to Ipswich."