Gillingham 3 Portsmouth 2
Plucky Gillingham came from behind twice and punished Portsmouth for a missed penalty late on with an extra-time winner.
It was evident from the opening five minutes that Portsmouth wanted to quickly stamp their Premiership authority on the encounter and their aim appeared to be to use both flanks to stretch Gillingham.
Pompey should have opened the scoring on seven minutes as they went on the attack. Gary O'Neil slipped Matthew Taylor clean through on goal and his shot, from just inside the box, came crashing back off the bar.
Azar Karadas was denied by a last-ditch tackle by Michael Flynn as he went to shoot before Portsmouth's pressure paid off with the opening goal on 24 minutes. Dario Silva broke on the right and pulled the ball back for O'Neil to finish first time.
Gillingham levelled in bizarre fashion three minutes before the break. Darren Byfield was off the pitch after receiving treatment and referee Tony Bates waved him back on at the same time as Jamie Ashdown rolled the ball out.
Byfield ran on to it and, with Ashdown exposed off his line, drilled a 20-yard shot past him.
Just a minute into the second half Brent Sancho was adjudged to have fouled O'Neil in the box and Taylor put away the penalty, but Byfield's 20-yard shot on 55 minutes struck a post before rebounding off the despairing Ashdown to level the scores again.
Pompey substitute Svetoslav Todorov should have won it on 86 minutes only to slice well wide from the penalty spot and in extra-time Gillingham caused an upset thanks to Andrew Crofts' 94th minute winner.