The Northern Premier Division outfit held a two-goal advantage at the break thanks to a Robert Dale brace, but three goals in six second-half minutes helped Gary Rowett’s side avoid a huge upset.
Lee Novak reduced the deficit within two minutes of the restart, before a quick-fire double from Wes Thomas put the Blues ahead.
Blyth pushed for an equaliser but were unable to find a third goal, as Birmingham progressed against a side 120 places below them in the league pyramid.
Nikola Zigic was handed a rare start up front for the Blues and the 6ft 8ins front man had the ball in the net after eight minutes, only to see the effort disallowed for a foul in the build-up by Michael Morrison.
Zigic missed a golden chance two minutes later when Novak crossed from the right and the towering striker somehow contrived to sweep the ball over the bar from seven yards.
The visitors came to rue their early opportunities and goalkeeper Colin Doyle almost handed the hosts the lead on a plate when his kick ricocheted off Daniel Maguire and dropped inches wide.
Blyth made their breakthrough in the 35th minute when Rivers wriggled between Neal Eardley and Guy Moussi on the left side of the box, to cross low for captain Dale to slide home a cool opener for the non-league side.
And seven minutes later Dale struck again, picking up Stephen Turnbull’s short free-kick and twisting into the box before unleashing a superb right-footed drive to the right of the diving Doyle.
Doyle palmed away a rising shot from Maguire in first-half injury time and the visitors left the pitch looking shell-shocked and desperately in need of an early breakthrough.
Novak sparked the visitors’ dramatic comeback when he drilled home in the 52nd minute, moments after Blyth goalkeeper Peter Jeffries had bravely plucked the ball off Mark Duffy’s toes.
Thomas then turned the game on its head with two goals in four minutes, with an angled drive from the edge of the box followed by a 58th-minute header which squirmed over the line.
Dale went close to completing a hat-trick in the 65th minute but fired wide, with Blyth showing they were anything but beaten.
Substitute Danny Parker headed wide in the dying minutes and Maguire later blazed a shot over the bar, as the home side went down fighting.