England secured a nail-biting three-wicket victory at Trent Bridge to secure their pre-World Cup series against Pakistan in front of a sold-out Nottingham crowd.
Pakistan set the hosts 341 to win the fourth Royal London One-Day International, after Babar Azam struck 115 and Fakar Zaman and Mohammad Hafeez hit fifties.
Jason Roy marshalled the early chase with 114 and - despite a middle-order collapse - Ben Stokes guided England over the line with a composed, unbeaten 71.
At the start of the day, stand-in captain Jos Buttler won the toss and put Pakistan in to bat under overcast skies, unleashing the pace duo of Jofra Archer and Mark Wood, both returning to the side as England made five changes.
Archer, in just his third One-Day International, and Wood, pulling on England colours for the first time this summer, lived up to their billing, combining to deliver an average pace of in excess of 89mph over the first eight overs.
The pace of Wood accounted for the dangerous Imam-ul-Haq who was forced to retire hurt on three from 13 deliveries after a rasping bouncer connected with his left elbow.
Fakhar Zaman joined Babar Azam and the duo made slow but undisturbed progress as England cycled through their bowlers, including five overs from the leg-spin of Joe Denly.
The pair had both made it to fifty in quick succession before Tom Curran returned to dismiss Zaman for 57.
Mohammad Hafeez, making his first appearance of the tour, kept Pakistan in the hunt for a competitive score alongside Azam, albeit the visitors were scoring at a somewhat slower rate below than spectators have become accustomed to at Trent Bridge in recent times.
At the 30 over mark the score had progressed to 178-1 and, shortly after reaching his half-century, Hafeez fell to the impressive Wood, whose pace in his second spell lacked nothing in comparison to his first.
Azam, world's number one batsman in T20 cricket, eased serenely to a ninth ODI century off 104 deliveries.
An acceleration to his scoring was evident after he had reached the milestone, but he managed just 15 more, caught on the boundary by Archer to hand Curran his second scalp.
Asif Ali came and went for a quickfire 15, Wood providing the catch to give Archer (1-62) his first Trent Bridge international wicket. Imad Wasim became Curran’s third victim, dismissed for a nine-ball 12.
Wood's final over, the 47th of the innings, brought a bizarre occurence. Malik, who had provided some much-needed acceleration for Pakistan with 41 from 26 balls, misjudged the location of his own stumps and proceeded to dismantle them with his bat.
Wood, who was touching 90mph for the majority of his ten overs, ended his allocation with figures of 2-72, to further complicate England’s fast bowling selection for the upcoming ICC Cricket World Cup.
Curran, the pick of the English bowlers, removed Hasan Ali to finish with figures of 4-75.
The injured Ul-Haq stepped back out to join Sarfaraz Ahmed but was clearly hampered by his bruised elbow and only managed to add a further three from seven balls.
That meant any late innings momentum rested on the shoulders of the Pakistan skipper, a task Sarfraz took to with relish bashing an unbeaten, 14-ball, 21.
The tourists’ batsmen had posted a score in excess of 300 for the third ODI running, finishing on 340-7, but with a good pitch, a fast outfield and short boundaries, Pakistan were thought to be some what short of a par score.
Under the early evening lights, Pakistan’s bowlers kept an early restraint on England’s usual free-scoring powerplay antics.
However, Jason Roy and his new opening partner James Vince were still able to muster 68 from the first ten, the former giving Pakistan their only chance when he was dropped on 25.
That lifeline would prove costly, but Pakistan did have a breakthrough after the opening pair had added 94, Vince bowled by youngster Muhammad Hasnain for 43.
England’s 100 came up at the end of the 14th over as Roy passed 50 and the Surrey opener broke a relative period of quiet progress with a brace of maximums, a brutal pull following an innovative scoop.
Roy continued to use the small boundary to his advantage as he neared three-figures, cutting Hafeez for four before lofting him off the back foot for a maximum to go a 75-ball hundred, his eighth in ODI cricket and first in the series, to go with back-to-back fifties.
Pakistan’s fielding let them down yet again as Root was dropped on 33, but Roy fell shortly after, strangled down the leg side, sparking an England collapse.
Root followed Roy back to the dressing room in the next over, caught superbly by a juggling Hafeez at short third man and Buttler followed just two balls later, somehow managing to chip a Wasim full toss into the hands of short fine leg.
Pakistan had all of a sudden found their fielding mojo and Zaman was the next to hold on to a fine running catch to dismiss Moeen Ali without scoring, England slipping to 216-5 and still 125 adrift of their target.
The spell of four wickets for 15 runs inside 17 deliveries checked England’s progress, with Ben Stokes and Joe Denly playing patient cricket in the immediate aftermath.
Denly, who had a rare chance to show his abilities with the bat, had made it to 17 when Junaid Khan pulled off a brilliant one handed catch off his own bowling.
Curran survived a run out scare early in his innings and alongside Stokes took the game into the final five overs needing 44 to win, as England’s premium all-rounder reached a 52-ball fifty.
The pair continued to pile the pressure on the Pakistan fast bowlers, bringing up their fifty stand inside 38 balls, Stokes celebrating by smashing Hasnain into the stands for a second maximum.
Curran’s cameo came to an end in the very next over, Hasan nailing his yorker to bowl the England youngster for a 30-ball 31.
The equation had been whittled down to 19 needed off 12 before a timely Stokes maximum and Adil Rashid's edged boundary left three required off the final over.
Three singles were enough to hand England the nervy victory, with Stokes and Rashid having added an unbeaten 22 for the eighth wicket.
The final game of the series takes place at Emirates Headingley on Sunday (11am start) as England look to complete a clean sweep heading into the World Cup.
The last few seats are available for Australia v Bangladesh at Trent Bridge on Thursday 20th June, priced from £20 for adults and £6 for juniors. Tickets can be purchased from the official ICC Cricket World Cup Ticketing Site.