Two goals inside three minutes early in the second half secured Birmingham a 2-0 win on a frustrating afternoon for Neil Warnock's Middlesbrough.
Warnock had hoped to enjoy a fourth straight win but the Middlesbrough boss was left wondering how Birmingham were able to take the comfortable lead after the restart.
Boro goalkeeper Joe Lumley was guilty of gifting Marc Roberts the opening goal for Birmingham eight minutes into the second half.
And Scott Hogan scored his fourth of the season soon after to secure back-to-back wins to move Birmingham up to 14th in Sky Bet Championship.
That meant Middlesbrough's hopes of moving back into the top six were dashed.
The game started slowly with neither side causing the goalkeepers trouble in the opening 20 minutes.
Birmingham, who ended a run of seven matches without a win by beating Swansea a week earlier, recorded the first effort when Jordan Graham curled over from distance.
A few minutes later striker Uche Ikpeazu headed wide at the other end for the home side when Onel Hernandez and Martin Payero had linked well down the left to create space to cross.
Middlesbrough felt Birmingham should have been reduced to 10 men soon after when defender Dion Sanderson, who had earlier been booked for pulling down Andraz Sporar, conceded a free-kick for wrestling Ikpeazu to the floor.
But referee Joshua Smith insisted that the error did not deserve a second caution and Sanderson survived.
Birmingham goalkeeper Matija Sarkic made the best save of the half when he dived right to push away Payero's free-kick that threatened to fly straight in from a tight angle.
With seconds remaining of the first half Sarkic was on hand again to deny Jonny Howson from picking out the bottom left corner of the Montenegro goalkeeper's net.
Birmingham showed plenty of nice touches in possession but were unable to create a meaningful opening for strikers Troy Deeney and Hogan during that opening period.
But Middlesbrough gave the visitors a helping hand soon after the restart when Lumley left his goal completely unguarded.
Lumley charged 12 yards from goal to try to punch a Graham free-kick into a crowded area and Roberts jumped first to head the ball into the empty net in the 53rd minute.
Less than three minutes later it was two when Deeney's ball in behind the defence allowed Hogan to beat Lee Peltier and Sol Bamba to it before he slotted low and beyond Lumley.
Despite having 34 minutes remaining Middlesbrough could not find the spark required in the final third to pull level.
The nearest Sarkic came to conceding before the end was when he missed a deep cross into his area and Roberts was on hand to clear with red shirts lurking.
What the managers said...
Middlesbrough's Neil Warnock: "I will still be disappointed when I get home tonight. I will still be horrible to be with sat next to my missus. I don't think it changes too much how many games I have had, but I don't think I will forget nights like tonight when I do call it a day, when I am fishing and managers are being put through the mill.
"Because I have done 1600 games you have to get over difficult results otherwise it drives you daft. I don't know how I have done that many games to be honest. It is an incredible achievement and I don't even think I realised myself what an achievement it was. But I hate losing like that, I don't think they won it I think we threw it away."
Birmingham's Lee Bowyer: "It was a good away, solid performance. Very professional. We deserved to win the game.
"We could have taken control of the ball in the final third better and we would have more. That opening goal was the pivotal point of the game. I thought the keeper would get there but Roberts got there and I was pleased it went in. We were solid, all three centre-halves looked comfortable whatever they threw at us."