Pat Cummins steered Australia home with the bat during a tense finish to earn his side a two-wicket win over Pakistan in the opening one-day international in Melbourne.
Having bowled Pakistan out for 203, Australia looked in danger of falling short in their run chase after a middle-order collapse saw them slump from 139-3 to 155-7 in the first of the three-match ODI series.
Playing his first ODI since last year's World Cup in India, Cummins then produced an unbeaten 32 from 31 balls to push the hosts to the modest victory target with 16.3 overs to spare.
"It got a bit tighter than we would have liked in the end," Cummins admitted. "Really happy with how the guys bowled, everyone really."
Mitchell Starc had earlier impressed with the ball, taking 3-33 - including both of Pakistan's openers - to limit the visitors' bid for a sizeable total after they had been sent into bat.
Babar Azam made 37 off 44 balls before being bowled by leg-spinner Adam Zampa (2-64) with an ill-judged push at a straight delivery, while Cummins (2-39) removed Kamran Ghulam for five the following over.
Mohammad Rizwan top-scored for Pakistan with 44 and ODI debutant Irfan Khan made 22 batting at seven before being run out, with only some late aggressive hitting from Naseem Shah (40) and Afridi (24) pushing Pakistan past 200.
Australia were missing four from the team that thrashed India in the World Cup final, with David Warner having retired, paceman Josh Hazlewood rested and both Travis Head and Mitchell Marsh on paternity leave.
Openers Matt Short (one) and Jake Fraser-McGurk (16) both fell early in reply but Australia were seemingly cruising after reaching 112-2 in the 17th over, only for the loss of Steve Smith for 44 to Haris Rauf (3-67) changing the contest.
Josh Inglis - having top-scored with 49 of 42 balls - was dismissed soon after for the first of three wickets in five balls, as Rauf removed Marnus Labuschagne and Glenn Maxwell with successive deliveries in the next over.
Aaron Hardie was bowled by Mohammad Hasnain for 19 and Sean Abbott was run out for 13 to leave Australia eight down and still needing 19 more runs, but Cummins and Mitchell Starc (two not out) saw them to victory.
The series continues in Adelaide on Friday (3.30am start UK time), with the third and final ODI then held in Perth on Sunday.