Garry Monk's return to Swansea saw his 10-man Birmingham side denied at the death as Oli McBurnie scored twice in a thrilling 3-3 draw.
Blues boss Monk, who spent 10 years as a player with the Swans before taking over his manager, was making his first appearance in the opposition dug-out at the Liberty Stadium.
Visiting defender Kristian Pederson was sent off for two first-half bookings after Jacques Maghoma had cancelled out Dan James' opener for the hosts.
In the second half McBurnie put Swansea back in front, but Blues captain Michael Morrison levelled and striker Che Adams curled a sublime strike into the bottom corner from 25 yards to turn the match on its head.
However, there was still time for McBurnie to bundle home an equaliser in the 94th minute as both teams had to settle for a point.
The hosts dominated the first half, Nathan Dyer appealing for an early penalty and captain Leroy Fer, making his 100th appearance for the club, had a back-heel attempt blocked.
Fer's evening came to a premature end after only 16 minutes as he limped off to be replaced by Jay Fulton, but it did not disrupt Swansea.
James soon put them ahead, playing a a neat-one two with McBurnie, who had already had two chances of his own, and letting fly with his left foot.
The effort was straight at Birmingham goalkeeper Lee Camp and he should have done much better as the effort beat him far too easily.
Monk's side started tamely and it was a surprise to see them level before the break.
Maghoma had fired over when presented with an earlier opportunity, but, given a second chance, he was allowed too much toom by Kyle Naughton and capitalised by firing past Erwin Mulder.
Referee Stephen Martin handed out six first-half yellow cards and Pederson, who had already been booked, scythed down McBurnie and saw red.
There was still time before the break for Camp to redeem himself by superbly tipping a Matt Grimes free-kick over.
Lukas Jutkiewicz had a shot deflected wide when the game resumed as the energy drained out of Swansea.
Swans boss Graham Potter responded by bringing on Jefferson Montero, switching Grimes to left-back, and pushing Naughton into midfield.
Fulton had a flicked effort saved and Bersant Celina fired wide before McBurnie headed home a superb Montero cross.
But just two minutes later Morrison bundled home following a goalmouth scramble as Mulder flapped hopelessly at a long ball.
Adams then looked to have won it, but Swansea huffed and puffed for an equaliser and they eventually got their reward as McBurnie swept home Mike Van Der Hoorn's knock down to extend their unbeaten run to seven games.