Substitute Scott Hogan was the penalty hero as his late spot-kick gave Birmingham a much-needed 1-0 win against promotion-chasing Swansea after team-mate Lukas Jutkiewicz had missed one.
Irish international Hogan blasted his penalty past goalkeeper Freddie Woodman in the first minute of added time after Ivan Sunjic had been bundled over by substitute Yan Dhanda.
The result - Blues' second home win in a row under new head coach Lee Bowyer - moved them up to 20th and six points above the relegation zone, but third-bottom Rotherham have four games in hand on them.
Third-placed Swansea suffered their third straight loss and appear to have almost blown their chances of automatic promotion as they are now nine points off second place.
Meanwhile, two former Ireland international team-mates mete at Cardiff City Stadium where Chris Hughton's Nottingham Forest held Mick McCarthy's playoff-chasing Cardiff City with the only goal of the game coming from James Garner.
League leaders Norwich City were held to a 1-1 draw by Preston at Deepdale while second-placed Watford edged past Sheffield Wednesday 1-0 at Vicarage Road.
There were home wins for Queens Park Rangers (3-0, v Coventry), Millwall (1-0 over relegation threatened Rotherham), Derby County (2-0 over Luton) while Bournemouth kept up their playoff quest with a 3-1 defeat of Middlesbrough.
Stoke City (2-0 at Bristol City) collected all three points of their travels, as did Hughton's Forest.