Iain O'Brien and Daryl Tuffey bowled New Zealand into a dominant position in the deciding Test against Pakistan in Napier.

Pakistan captain Mohammad Yousuf opted to bat after winning the toss but was grateful for a near single-handed effort from opener Imran Farhat, who carried his bat to finish 117 not out in a total of 223.

O'Brien, in his final Test match, ripped through the top order with a spell of four for 15 in eight overs in the morning session and Tuffey had the last four batsmen caught behind.

New Zealand openers Tim McIntosh and BJ Watling then put on 47 before bad light ended play.

In a frantic morning session, Farhat and opening partner Salman Butt put on 14 before the latter was bowled playing across a Tim Southee inswinger.

O'Brien made an immediate impact after his introduction at first change, cramping Faisal Iqbal in his first over with a rising delivery which the batsman, who made just six, could only loop into the hands of Martin Guptill at gully.

And the next three batsmen failed to trouble the scorers as O'Brien ran riot.

The 33-year-old will retire after the series to be with wife Rosie in England, and will continue his career with Middlesex.

And he was in the mood to go out with a bang as some hostile bowling and genuine pace snared him three more wickets.

Yousuf, continuing to lead the side in the absence of Younus Khan, was the next to go as he flashed at a short delivery and edged to slip McIntosh.

And Umar Akmal and Misbah-ul-Haq both fell in O'Brien's fifth over - giving him figures at that stage of four wickets for three runs - Umar prodding tamely to Guptill before Misbah followed four balls later after an edge to wicketkeeper Brendon McCullum. O'Brien finished with four for 35.

Farhat found some overdue support as Kamran Akmal reached lunch on 18 not out, but the wicketkeeper was dismissed for 22 by Chris Martin in the first over after the resumption when he bailed out of a pull stroke and miscued the ball to cover point to offer Guptill his third catch of the innings.

Mohammad Aamer, though, showed admirable restraint after his team-mates' rashness earlier in the innings and played a supporting role as Farhat advanced beyond 50.

The opener's half-century came up in 74 balls, with eight boundaries, as he pushed Martin to point for a single shortly after Akmal's departure.

And the pair went on to add 69 for the seventh wicket before Aamer fell, nicking Tuffey to McCullum after making a diligent 23 from 82 balls.

Umar Gul carried on in a similar vein, his 24 representing the second-highest score of the innings before he and Mohammad Asif fell in successive deliveries.

Last man Danish Kaneria crashed 16 in boundaries from 13 balls before another outside edge gave McCullum his fifth catch, four of them off Tuffey (four for 52).

Pakistan threatened to make early inroads but to no avail.

McIntosh survived a third umpire review of an lbw appeal from Asif, replays suggesting the ball was going over the top, and was reprieved again when Yousuf missed a run-out chance with him well out of his ground.

But he picked up after a pedestrian start to reach 31 not out by the close of play, with Test debutant Watling 13 not out at the other end by the time the pair were offered the light two overs ahead of the scheduled close.