Scott Hogan succeeded where Lukas Jutkiewicz had failed to give Birmingham three vital points in their fight against relegation.
Blues’ chances of beating Swansea looked to be fading after Freddie Woodman kept out Jutkiewicz’s first-half spot-kick for his fifth penalty save in eight games for the club.
But when substitute Yan Dhanda brought down Ivan Sunjic in stoppage time, Hogan – who had replaced Jonathan Leko eight minutes from time – gave Woodman no chance from the spot to make it two wins from two home games for new boss Lee Bowyer.
Scott Hogan scored a penalty in injury time to give Birmingham a priceless win vs Swansea
The victory could be crucial in Blues’ bid to survive in the Championship this season
Yan Dhanda slipped to give away a needless penalty which would ultimately cost his side
MATCH FACTS AND PLAYER RATINGS
Birmingham XI: Etheridge, Roberts, Colin, Dean, Pedersen, Gardner (Harper, 90′), Seddon (Friend, 46′), Sunjic, Halilovic (Toral, 68′), Jutkiewicz (Hogan, 82′), Leko (Cosgrove, 82′)
Subs not used: Andres, Bela, McGree, San Jose
Goals: Hogan (90+2′)
Booked: Seddon (45+2′)
Manager: Lee Bowyer
Missed penalty: Jutkiewicz (32′)
Swansea XI: Woodman, Naughton, Bennett, Bidwell, Guehi, Roberts, Smith (Dhanda, 70′), Grimes, Fulton, Lowe (Routledge, 89′), Ayew
Subs not used: Hamer, Manning, Hourihane, Whittaker, Latibeaudiere, Cooper, Cabango
Manager: Steve Cooper
Manager: Tony Harrington
The win allows Blues to edge further away from the bottom three though Rotherham, who are six points behind, have four games in hand due to a Covid-19 backlog. Swansea, meanwhile, remain third but are now nine points behind second-placed Watford.
Though they have stayed in the automatic promotion hunt, Swansea have lacked fluency in recent times and the early exchanges set the tone for a slug fest on the bare St Andrew’s pitch.
Jamal Lowe could have put Swansea ahead in the seventh minute but Neil Etheridge, the former Cardiff goalkeeper, did well to turn his angled effort over the bar.
Alen Halilovic, once on the books of Barcelona and AC Milan, was playing in a free role just behind the forwards and he was Blues’ most creative player in the first half.
In the 25th minute the Croatian found shooting space on the edge of the box after a short corner, only to fire high and wide. He was more accurate from a similar position two minutes later and Swansea were relieved to see the ball clip Jutkiewicz and slide behind.
Jutkiewicz then missed a golden chance to put Blues in front. Marc Roberts’ long-throw caused panic in the Swansea box and Connor Roberts brought down Jonathan Leko. Jutkiewicz’s fiercely-struck spot-kick was saved by the legs of Woodman.
Hosts missed a golden chance to take a shock lead when Lukas Jutkiewicz’s penalty was saved
Connor Roberts brought down Jonathan Leko leading to the penalty being given to Blues
Swansea were hoping to close gap on top two against Championship strugglers Birmingham
After a bright start by the hosts, Swansea grew into the game as they searched for the winner
The defeat leaves Swansea nine points off the top two as hopes of automatic promotion fade
Mindful of their escape, Swansea started the second half with much more purpose and pinned Birmingham back. Like the home side, though, they could not make early set pieces count.
On the hour mark, Andre Ayew found Lowe in space and the forward turned quickly and shot, with Harlee Dean doing well to block.
Then substitute Yan Dhanda saw his free-kick from 20 yards well saved by Etheridge.
That looked to be that until Dhanda’s needless foul on Sunjic was punished by Hogan.