Championship side Swansea earned a place in the fourth round of the Carling Cup after a hat-trick from former Chelsea winger Scott Sinclair accounted for League One pacesetters Peterborough at London Road.
Sinclair, a constant thorn in the side of the Peterborough defence all evening, tested former England Under-21 international goalkeeper Joe Lewis after just two minutes.
The Swansea winger cut inside and unleashed a 20-yard shot that Lewis punched clear.
But three minutes later the visitors were ahead when Sinclair danced through the Peterborough defence before his shot was deflected into the net via Lewis and defender Gabriel Zakuani.
The lead lasted just 60 seconds though as Peterborough unlocked the Swansea defence with ease.
Charlie Lee sped into the penalty area before crossing for the unmarked Craig Mackail-Smith to drill home the equaliser.
The home side were unlucky to go in front two minutes later when George Boyd's pass found Aaron McLean in space on the edge of the six-yard box but Yves Makabu-Makalambay saved superbly.
In the 37th minute, Sinclair brought another fine save from Lewis with a curling shot before he latched on to a pass from David Cotterill to put the visitors back in front four minutes later.
Peterborough felt they were unlucky not to have two penalties but referee Nigel Miller rejected their appeals.
The official was at the centre of much controversy throughout the second half by failing to award clear free-kicks to both sides.
Swansea should have put the game beyond Posh's reach on the hour but Stephen Dobbie missed from six yards - a misdemeanour repeated by Sinclair in the 75th minute.
Sandwiched in between those misses were two close efforts from Peterborough. First Boyd sent a shot just wide of the right-hand upright and then, in the 73rd minute, substitute Lee Tomlin brought a fine save from Makabu-Makalambay - only for referee Miller to award a goal-kick.
But Peterborough's miserable night was completed inside two minutes. In the 76th minute, Tomlin supplied a superb cross for Mackail-Smith, but the Posh striker somehow contrived to fire over the bar from two yards out.
The miss was punished almost immediately when Dobbie's backheel put Sinclair through on goal and the winger picked his spot from six yards to make it 3-1.
Sinclair's third goal killed off Peterborough's resistance and although they huffed and puffed until the final whistle, they only came close once to reducing the arrears but Mackail-Smith was again denied by Makabu-Makalambay.