Ajaz Patel took a five-wicket haul on debut as New Zealand pulled off an unlikely four-run victory over Pakistan in the first Test in Abu Dhabi on Monday to go 1-0 up in the three-match series.
Pakistan were overwhelming favourites on Monday, resuming the fourth day on 37/0, needing another 139 runs to win to reach the target of 176.
They lost three early wickets though as Patel got rid of opener Imam-ul-Haq (27) while Kiwi leg-spinner Ish Sodhi accounted for Mohammad Hafeez (10) and Haris Sohail (4) as Pakistan slipped to 48/3.
Azhar Ali and Asad Shafiq buckled down and added 82 runs for the third wicket, and at 130/3, it looked if the game was done and dusted with only 46 runs to get and seven wickets in hand.
However, the New Zealand are known to be a team of fighters that always punches above their weight in sporting contests and never gives up.
And that spirit came through as left-arm seamer Neil Wagner made the crucial breakthrough when he get rid of Shafiq for 45.
Babar Azam (13) and Azhar took the total to 147 but the former was run-out just as he looked as if he was getting set.
What followed though was an almighty collapse as Pakistan slipped from 147/4 to 164/9 within the space of less than eight overs.
Azhar was still at the crease and all hope was with him as last man Mohammad Abbas survived some tense moments as they inched closer to their 176-run target.
Patel though managed to take the final wicket when he trapped Azhar lbw for 65 to set off wild celebrations by New Zealand players and coaching staff.
The second Test of the three-match series starts in Dubai on Saturday.
Archer claimed two wickets and sent opener John Campbell back hurt before lunch.
The pair repelled the best Australia could throw at them for 11 and a half overs.
All three results are possible, with England ending day four 248 for eight – a lead of 170 runs on a wearing pitch.
Alzarri Joseph and Shannon Gabriel shared four wickets in the final hour to peg back England.
England are 170 ahead with two tail-end wickets in hand after a frantic final hour on day four.
The hosts were 168 for three at tea, 54 in front.
England reduced the deficit to 35 before lunch.
Broad was dropped from the series opener against the West Indies as Anderson, Mark Wood and Jofra Archer were preferred.
Stand-in captain Ben Stokes kept England in the game with three late wickets on day three.
The captain took four wickets before England closed the day on 15 without loss.