Patrick Agyemang climbed off the bench to light up lifeless Pompey and lead them into the next round of the Johnstone’s Paint Trophy.
Guy Whittingham’s men were comfortably second best and had only one shot on goal by the time the powerful striker was introduced in the 59th minute against Oxford.
Replacing Romain Padovani, it prompted the visitors to revert to two up front as Agyemang recreated the strike partnership with John Marquis which lined up against Rochdale.
Within six minutes, the former Wimbledon man had crashed home a classy finish with the outside of his right foot to put the Blues on the way to what had looked an unlikely victory.
Marquis increased the lead in the 82nd minute – heading home Yassin Moutaouakil’s pin-point right-wing cross to send the 1,132 away fans wild.
Even before then Pompey could have scored on several occasions such was the impact of Agyemang’s opener in galvanising his team-mates.
James Constable sparked a few nerves when he pulled one back in the 89th minute to give Oxford a glimmer of hope.
But there was no coming back from Chris Wilder’s side as they finished a shadow of the team which had run the visitors ragged during the opening 45 minutes.
Instead it was Whittingham’s troops who grew stronger as the second half wore on to win 2-1.
And they now find themselves in the third round of the Johnstone’s Paint Trophy.
The Blues boss made three changes to the side which strolled to victory over Rochdale at the weekend – and an alteration to his system.
Moutaouakil was brought back in after serving a three-match suspension, with Joe Devera rested from the squad.
Thery Racon was another missing after making his first start since April in that 3-0 win over the Dale, Padovani coming in for him.
Finally, Gavin Mahon was given his Pompey debut in the centre of midfield, with Agyemang dropping to the bench leaving Marquis as the sole striker.
The five-man bench was without injured trio David Connolly, Simon Ferry and Danny East – as well as John Sullivan, Devera, Dan Butler and Tom Craddock.
The match got under way with Oxford starting the brightest amid a scattering of soft free-kicks given away by the visitors.
The hosts were looking confident.
They knocked the ball around well in the early stages, suggesting they would be difficult to break down – while Ryan Williams, in particular, was lively.
A dangerous move down the left in the sixth minute saw Tom Newey deliver a pin-point cross on the run.
But Williams clambered all over Sonny Bradley at the far post to concede a free-kick.
Williams was heavily involved and in the 13th minute, cutting across from the right flank past several challenges and firing in a left-foot shot which was bravely blocked by the midriff of Johnny Ertl.
Blues keeper Trevor Carson was next forced into a point-blank save from eight-yards out when Constable swivelled to fire in a powerful shot which was beaten away.
Moments later Marcos Painter hobbled off to be replaced by Shaun Cooper, the versatile performer slotting in at left-back for his first appearance since injury.
Still the U’s applied the pressure and Bondz N’Gala and Constable were neck and neck in a 20th-minute race for a through ball.
But the Pompey man managed to snake out a foot to get there first, with only Carson standing between Constable and an opening goal.
Michael Raynes should have broken the deadlock in the 28th minute when he was allowed to meet Callum O’Dowda’s right-wing cross with a free header.
But he could only nod the ball wide of the target.
Josh Ruffels then fired a first-time shot over from just outside the box after Williams had dispossessed a careless Ertl as he headed back towards his own penalty area.
It took until the 54th minute for Pompey to have their first attempt on goal – a swivelling half-volley from Romain Padovani which was comfortably dealt with by the keeper.
Regardless, the effort was given an almighty cheer from the visiting fans.
At the other end, poor communication between N’Gala and Moutaouakil eventually saw the latter under hit a backpass to Carson.
But the keeper got him out of jail and cleared with Constable bearing down.
Oxford were given a free-kick in a dangerous position down the left when Wallace felled O’Dowda.
However, Scott Davies could only fire it well wide of the intended target.
Still the Blues were under pressure and on the hour mark Davies picked out Constable whose header was parried by Carson and then hooked clear at the far post by Moutaouakil while under pressure from Deane Smalley.
Pompey responded with a second shot, this time a drive from Ertl along the ground from outside the penalty area which was comfortable wide of the left-hand post.
Then in the 64th minute Marquis produced a great turn and fired in a sublime half-volley which dipped just over the crossbar with Clarke struggling in the Oxford goal.
Barely 60 seconds later and Pompey had broken the deadlock.
Agyemang had only been on the pitch as a substitute for six minutes when he cut in from the right and unleashed a shot with the outside of his right boot which flashed into the far corner. It was a classy finish from the striker and overall against the run of play – but Whittingham’s men had their noses in front.
In the 73rd minute, Clarke produced a stunning low stop to prevent Holmes from extending Pompey’s lead.
And when Agyemang attempted to turn the loose ball back across goal the keeper intervened again.
Next Marquis charged down a clearance to find himself clear on goal.
But instead of burying the Blues’ second goal, the on-loan Millwall striker could only watch as the keeper got the slightest of touches to nudge it for a corner.
Marquis did have his name on the scoresheet in the 82 minute, though, as he met Moutaouakil’s cross with a clinical header.
Constable lashed a goal from close range a minute from time to spark the nerves ahead of three minutes of time added on.
But Whittingham’s side comfortably held on to make it successive wins and progress in the competition.