The winger scored an injury-time winner as Alessandro Del Piero ended up on the losing side.
Marcelo Adrian Carrusca opened the scoring just nine minutes into the friendly at the ANZ Stadium but Fernando Llorente headed home an equalizer for the Bianconeri just before hour mark.
Tomi Juric's 77th-minute strike looked to have won it for the All-Stars but Pogba hammered home a half-volley before Pepe snatched a last-gasp winner after pouncing on a loose ball in the box.
A lively start from the hosts saw former Juventus star Alessandro Del Piero have the first sight of goal after eight minutes. The World Cup winner's free kick struck the wall, but a minute later the All-Stars were ahead through Carrusca.
MORE: Biggest summer transfers | Soccer's beautiful fans | WAGs
Matt Smith brought the ball confidently out of defense to begin a flowing move that ended with Carrusca cutting inside Angelo Ogbonna, before firing low into the bottom corner of Gianluigi Buffon's net.
Juve was struggling to cope with its opponent and nearly fell further behind at the half-hour mark as Besart Berisha forced Buffon into a smart save, the experienced goalkeeper pushing a curling shot wide.
The visitors gradually found their stride as Andrea Pirlo began to dictate proceedings, and a neat move between the Italian champion's front two almost brought an equalizer.
Carlos Tevez and Llorente exchanged passes on the edge of the penalty area but the Argentine's low shot struck a post before bouncing out for a goal kick.
Juve eventually equalized as Patrice Evra made good ground down the left and, after being found by Pirlo, delivered a pinpoint cross to find Llorente, who headed beyond Eugene Galekovic.
A host of changes gave the All-Stars a boost and with 13 minutes remaining they claimed what appeared set to be a winning goal, as Juric cut in from the left edge of the area and lashed the ball into the back of the net.
With time running out and Juve staring defeat in the face, it was Pogba who initially came to the rescue with a sumptuous volley over Mark Birighitti to level the match. But the drama was not over.
The All-Stars failed to clear a late Juve corner and Pepe latched onto the loose ball inside the penalty area to fire into the bottom corner and seal the victory.