Lionel Messi scored in a joint record 16th Champions League season as Barcelona stunned Ferencvaros to make a strong start in the new campaign.
17-year-old Pedri also netted his first senior goal for Barcelona.
Messi had scored a penalty to put the Catalan giants ahead after he was felled at the end of a weaving run.
Ansu Fati volleyed Barca’s second, with Philippe Coutinho adding a third.
Gerard Pique was sent off for a foul that set up Ihor Kharatin to narrow the deficit with a penalty, but Pedri and Ousmane Dembele, who was assisted by Messi, ensured Barca’s win.
Pique’s dismissal means he will not be available for Barça’s trip to Italian champions Juventus in gameweek two.