Birmingham reach League Cup final
With West Ham leading 2-1 after the first leg, the Londoners went further ahead thanks to a curling long-range strike from Carlton Cole in the first half before Birmingham turned things on their head after the break.
Midfielder Lee Bowyer struck against his former club and Roger Johnson levelled the tie on aggregate to send it into extra time as Birmingham woke up from their lethargy following the introduction of lively Serbia striker Nikola Zigic.
Gardner, who hit the post twice in normal time, finally found the net with a right-footed shot low into the left corner in the 94th minute to give Birmingham the lead for the first time in the tie and they held on to win 3-1 on the night.
"It's unbelievable... you only dream of these things," Gardner, a boyhood Birmingham fan, told Sky Sports. "I was saying to my mates before the game I'm going to get the winner and take us to the final. To actually do it is unbelievable."
What had started as a poor first half erupted into a thrilling match after Birmingham manager Alex McLeish sent on Zigic, whose huge physical presence proved the undoing of West Ham.
"It was his most effective game for us, when he plays like that he can be very very difficult to handle," McLeish said of the Serb. "We huffed and puffed a wee bit without troubling them (in the first half)... Zigic made the difference."
With both sides stuck in a Premier League relegation battle, the cup run has provided light relief from their day to day misery but for West Ham boss Avram Grant the spotlight will once again focus on his future at the league's basement club.
He had been on the verge of taking a relegation-threatened club to a cup final for the second successive year after beating the odds with Portsmouth in leading them to last year's FA Cup final where they lost to Chelsea. But he let it slip away.
Cole's opener followed a mix-up between Birmingham midfielders Barry Ferguson and Gardner and he unleashed a right-footed shot from 25 yards that curved in beautifully at the far post to put West Ham 3-1 up on aggregate.
What the visitors had not banked on was a totally different Birmingham emerging after the break and Zigic made an immediate impact by heading down a ball that Gardner struck into the inside of the post before it whizzed across goal.
Birmingham kept up the pressure and when West Ham failed to clear a corner Bowyer was lurking unmarked to send a left-footed volley into the top left corner in the 59th minute.
Twenty minutes later Johnson headed in and Gardner thought he had won it just before the end of normal time when his shot was turned on to the post by keeper Robert Green.
Instead the match went into extra-time and Gardner found it was third time lucky when his low drive finally found the net.
Scott Parker went just wide, Kieron Dyer volleyed just over and Cole shot straight at Ben Foster as West Ham pressed for an equaliser in a gripping finale but Birmingham hung on.