After Bilal Asif finished with 5 for 65 to bowl New Zealand out for 274, Trent Boult removed Mohammad Hafeez as Pakistan went to lunch 0/1.
Williamson missed out on a 19th Test century but Watling was unbeaten on 42 as New Zealand closed on 229-7
New Zealand, who won the toss and opted to bat, reached 229-7 at the close of the opening day of the third and final Test against Pakistan in Abu Dhabi on Monday.
Williamson ground out an obdurate 71 not out to take New Zealand to 145-4 at tea, defying Yasir during his unbroken fourth wicket stand of 73 with Bradley-John Watling who was unbeaten on 14.
Also retained is off-spinner Bilal Asif who has just five wickets to show in the last three Tests.
New Zealand reached 222/4 at lunch, still needing 106 runs to avoid an innings defeat.
The fifth wicket stand between Nicholls (51) and Watling (43) has so far yielded 92 runs as New Zealand -- conceding a 74-run deficit in the first innings -- extended their lead to 126 with six wickets standing.
Australia have slipped to fifth place in the Team rankings, while Pakistan are just two points behind sixth-placed Sri Lanka.
Australia surrendered eight wickets for 125 runs in 43.4 overs.
Mohammad Abbas and Bilal Asif combined to bowl out Australia for 145 - the fourth-lowest first-innings total in Asia.