Pakistan edged past England by three runs in a thrilling encounter in Karachi to level their Twenty20 series at 2-2.
Chasing 167, Liam Dawson put England on course for victory after smashing 24 runs off the 18th over to leave the tourists needing nine runs from 12 balls.
But an absorbing match swung Pakistan's way the following over when Haris Rauf took two wickets in two deliveries to leave England nine down with four runs still required.
Number 11 Reece Topley was then run out in the final over to seal the win for the home side and spark scenes of jubilation among the crowd.
Earlier, Mohammad Rizwan top-scored with 88 from 67 balls as Pakistan reached 166-4.
A disciplined England bowling performance restricted Pakistan to just three sixes in their entire innings, with two of those coming from Asif Ali in the final over, which proved vital.
England made a poor start to their reply and were reduced to 14-3 after two overs.
Harry Brook hit 34 from 29 balls and Ben Duckett 33 from 24 to lead the recovery, but England continued to lose wickets at regular intervals.
Dawson's late heroics nearly got them over the line, but he looked inconsolable as Pakistan hit back to bowl England out for 163 and seal a breathless win.
The teams will now travel to Lahore for the fifth T20 in the seven-match series on Wednesday.
More to follow.