Blackcaps v Pakistan: New Zealand secure scintillating last-gasp win at Bay Oval

New Zealand's bowlers produced a late final session surge to guide their side to a tense 101-run victory over Pakistan in the first test in Mount Maunganui on Wednesday to keep alive their hopes of reaching next year's World Test Championship final.

Pakistan were dismissed for 271, chasing a victory target of 372, with 4.3 overs remaining in the test at Bay Oval.

The victory lifts New Zealand momentarily to No.1 in the ICC test rankings, although that could change pending the outcome of the second test and the series between Australia and India.

"It was a brilliant game," NZ captain Kane Williamson said post-match.

"Both teams put their best foot forward and Pakistan were incredibly resilient in that second innings, but the boys kept coming.

"A huge effort by the bowlers to get us across the line."

New Zealand had been hot favourites to win the game as the final day started with the tourists 71-3 but a 165-run partnership between Fawad Alam and Mohammad Rizwan gave the tourists a chance of a draw, if not an unlikely victory.

Kyle Jamieson ended the partnership when he had Rizwan trapped in front, albeit after a review, for 60, and left Pakistan 242-6, still 131 runs away from their target with 25 overs remaining.

He also had Yasir Shah caught in the gully for a duck, while Neil Wagner, who has played the last three days with two broken toes, had Fawad caught by wicketkeeper BJ Watling for 102 and then Faheem Ashraf for 19 to expose the tail.

Mitchell Santner then trapped Mohammad Abbas in front for one, before he captured the last wicket when he had Nassem Shah caught and bowled for one with 4.3 overs remaining in the test.

"Not a huge disappointment (with the result)," Rizwan said. "That's test cricket.

"We lost this match, but we're still in the series."

The second match in the two-test series is at Christchurch's Hagley Oval from January 3 and New Zealand need to win that game as well to give them any chance of making the Test Championship final at Lord's.

NZ 431 (Williamson 129, Watling 73, Taylor 70, Nicholls 56, Shaheen 4/109)

Pakistan 239 (Faheem 91, Rizwan 71, Jamieson 3/35)

NZ 180/5d (Blundell 64, Latham 53, Naseem Shah 3/55)

Pakistan 271 (Fawad 102, Rizwan 60, Jamieson 2/35, Wagner 2/55)

Reuters.