The pair delivered an almost faultless 369-run fourth-wicket partnership, the third highest for any wicket in Black Caps Test history, as the hosts finished day three with a lead of 354 runs.
After New Zealand had declared on 659-6, the tourists were sent in to face 11 overs and the in-form Kyle Jamieson removed Shan Masood as Pakistan closed day three on 8-1.
Williamson had earlier posted another two blistering sessions to score a brilliant 238 and become the quickest of three New Zealanders to score 7,000 career Test runs.
The world’s top-ranked Test batsman notched his fourth Test double century and was supported by a gutsy 157 from Nicholls, who was hampered by a calf strain while bringing up his third Test 150.
Nicholls pushed through the pain barrier on his home ground at Hagley Oval to join Brendon McCullum as the only players with two Test hundreds in Christchurch.
Daryl Mitchell raced to his first Test century before the declaration, scoring 102 not out, as New Zealand recorded their fifth highest all-time Test total.
Kane Williamson brings up his double ton!— ICC (@ICC) January 5, 2021
What an innings by the New Zealand captain! That is his fourth double century - joint-highest with Brendon McCullum among batsmen!#NZvPAK SCORECARD https://t.co/eVFtwym5wgpic.twitter.com/gp0U4dlaqt
Starting the day 11 runs behind the tourists’ first-innings total, the hosts picked up where they left off yesterday with Nicholls bringing up his century off 213 balls for 315-3.
Limping between the creases, Nicholls dug deep to navigate the new ball and went on the attack, hitting the first six of the innings, as Williamson surged past 7,000 career Test runs.
The Black Caps skipper was once again putting on a clinic, punching his 21st boundary back past Naseem Shah to bring up the 300 partnership from 459 balls.
The 30-year-old continued to rack up the milestones, reaching 150 in 247 balls, and bringing up 400 on the final ball of the session as the hosts headed to lunch 103 runs ahead.
Nicholls came out playing some aggressive shots to record 150 in 285 balls, but his valiant innings came to a close six balls later when he hooked Mohammad Abbas' delivery to Naseem at third man.
BJ Watling entered at 440-4 but the wicketkeeper departed to Shaheen Afridi for seven, as Williamson guided New Zealand past 500 and, after a rain delay, sealed his fourth Test double ton in 327 balls.
Mitchell helped put on 133 runs for the sixth wicket as Williamson finally fell to Masood’s catch from Faheem Ashraf’s bowling after more than nine and a half hours at the crease for 585-6.
Mitchell survived a couple of scares to reach his maiden ton, adding a rapid-fire 74-run partnership with Jamieson (30 not out) that included 60 runs in the final 4.5 overs before the declaration arrived.
Trailing by 362 runs, Pakistan aimed to block out the day but Masood was caught by Tim Southee for his second duck of the Test match, leaving Abid Ali and nightwatchman Abbas to open day four.
Of course he does! Kyle Jamieson strikes with his second ball. Shan Masood goes caught by Tim Southee at 3rd slip. Mohammad Abbas now in as nightwatchman. Follow play LIVE in NZ with @sparknzsport#NZvPAKpic.twitter.com/tHhjvLjxxW— BLACKCAPS (@BLACKCAPS) January 5, 2021