Neither side was able to break the deadlock by half time, although on the quarter-hour mark David Stockdale's miscued clearance fell to Abdelhamid Sabiri, only for the ensuing effort to sail harmlessly wide.

The breakthrough came on 52 minutes for the Championship side when Lukas Jutkiewicz's headed flick-on fell to Che Adams, who had space to turn on the edge of the area before cutting a low shot beyond Jonas Lossl.

However, the Terriers equalised just after the hour through an own goal as Tom Ince rifled an effort towards Stockdale from the edge of the box, the goalkeeper making the save but then seeing the ball creep in via a Marc Roberts deflection.

Midway through the second half Jutkiewicz went down inside the box under a challenge by Matthias Jorgensen but the referee waved play on despite penalty calls from the Birmingham fans.

The game opened up in the latter stages as Stockdale pulled off a series of saves, while at the other end Adams's effort was cleared off the line by Jorgensen, but neither side could find a winner by the 90-minute mark.

Huddersfield continued to press and were rewarded by taking the lead in the fourth minute of extra time, Steve Mounie meeting Scott Malone's cross and heading the ball beyond Stockdale.

The Premier League strugglers then raced further ahead with a third just three minutes later, Rajiv van La Parra slotting in a rebound after Ince's effort was kept out, before adding a fourth on 106 minutes through Ince's fierce drive into the bottom corner.

The result sees David Wagner's charges earn a fifth-round home tie against Manchester United.