Australia pulled off a sensational last-over, six-run win despite a debut hundred by Pakistan's Abid Ali and second career century by Mohammad Rizwan in the fourth one-day international in Dubai on Friday.
Needing 278 to win, Pakistan were brought close to their target by Ali's 112 and Rizwan's 104 but in the end the twin hundreds were in vain as they failed to score a required 17 off Marcus Stoinis's last over.
The win gives Australia a 4-0 lead with the last match also in Dubai on Sunday.
Glenn Maxwell missed a second career hundred by just two runs, Usman Khawaja scored 62 and Alex Carey 55 as Australia posted 277-7 in their 50 overs.
Ali and Rizwan had put Pakistan on course for victory with a 144-run third-wicket stand but once Ali departed off leg-spinner Adam Zampa in the 42nd over, the innings wilted under the pressure of 60 runs in the last 8.5 overs.
Umar Akmal and debutant Saad Ali fell for seven each to paceman Nathan Coulter-Nile who finished with 3-53 while Stoinis had Rizwan and Usman Shinwari (six) in the final over to seal the win.
Ali, only drafted into the side two hours before the start after Imam-ul-Haq went down with fever, grabbed his opportunity, completing his hundred off 111 balls.
He was lucky to survive a leg-before appeal on 98 off Zampa as the review went on umpire's call. He took two singles to reach the three-figures mark.
Ali is the 15th batsman to score a hundred on one-day international debut. Salim Elahi (102 not out v Sri Lanka at Gujranwala in 1995) and Imam (100 v Sri Lanka in Abu Dhabi 2017) were the other two Pakistani batsmen to score debut ODI tons.
Ali hit nine boundaries in his 111-ball knock while Rizwan had a six and nine boundaries off 102 balls.
Earlier, it was Maxwell who lifted Australia - sent into bat - from 140-5 to an imposing total. Maxwell hit three sixes and nine boundaries in his 98 off 82 balls.
A new look Pakistan team, with Imad Wasim as skipper after Shoaib Malik was ruled out with a rib injury, caught Australia napping at 101-4 when Maxwell walked in.
Dropped on 10 by keeper Rizwan off Yasir Shah, Maxwell repaired the innings with a 134-run partnership for the sixth wicket with Carey who finished with 67-ball 55 for his maiden fifty with three boundaries.
Maxwell, bowled by fast bowler Usman Shinwari off a no-ball when on 76, was within a sight of his second ODI hundred when he was run out while attempting a double run.
Carey supported Maxwell as the pair beat the previous sixth wicket stand in Australia-Pakistan ODIs of 90 between Dirk Wellham and Rod Marsh at Sydney in 1981.
Australia lost in-form opener Aaron Finch for 39, one short of completing 4,000 one-day runs while Usman Khawaja made a solid 78-ball 62 with six boundaries before he was trapped leg-before by Yasir who finished with 2-57.
Wasim, who had figures of 2-56, dismissed Shaun Marsh (five) and Peter Handscomb (seven) while Mohammad Hasnain got the prized wicket of Finch before dismissing Carey off the last ball, grabbing 2-52.