Faf du Plessis scored a controlled century as South Africa declared on a formidable 481-8, their grip on the second and final Test at Centurion tightening as New Zealand lost their opening pair at the end of day two.
The fortunes of Du Plessis have changed dramatically since being dropped from the side for the fourth match against England at this ground in January, and, after supporting JP Duminy on day one, he took centre stage by ending a 20-month wait for his fifth hundred in the longest format with an unbeaten 112.
The Black Caps only managed to stem the tide through the efforts of South Africa-born Neil Wagner (5-86), who claimed his fourth five-wicket haul to keep the tail in check.
But after the Proteas declared they had enough overs to make inroads with the ball, and they did just that, Martin Guptill (8) and Tom Latham (4) removed early as New Zealand reached stumps at 38-3.
It could have been quite different, however, had a pull towards the deep square leg boundary from Du Plessis on 18 not slipped through the fingers of a sprinting Henry Nicholls and gone for six.
There was no such luck for Duminy (88) when his attempt at a similar shot off Tim Southee (1-114) was caught behind by BJ Watling, while Temba Bavuma fell to a short bouncer from Wagner for eight.
Stiaan van Zyl (35) helped the Proteas to 358-5 by lunch, but Du Plessis picked up the pace in the next session and laid the foundations for an 84-run partnership.
The captain, standing in for the injured AB de Villiers, grew accustomed to the shorter deliveries and subsequently surged from 59 to 80 off 15 deliveries, a sequence that included four boundaries, with his second maximum off Southee.
Wagner removed Van Zyl and sent the off stump of Vernon Philander (8) flying before Du Plessis found room at long leg for the two runs to take him to his hundred, leaping for joy having reached the milestone for the first time since December 2014.
After Mitchell Santner (1-62) removed Kagiso Rabada (7) he was hit for successive sixes in an excellent 13-run cameo from Dale Steyn, and things did not get any better for New Zealand.
Guptill's struggles continued as he was caught at third slip off Philander (1-10), while Latham may feel hard done by to have fallen to Steyn (1-18) when the on-field umpire's not-out ruling was overturned by the third umpire, who deemed he nicked back to wicketkeeper Quinton de Kock.
A mix-up between Ross Taylor (1) and skipper Kane Williamson (15 not out) resulted in the former being run out by a direct hit from short leg by Bavuma, and although the tourists managed to make it to the close of play without further loss, Williamson and Nicholls (4 no) will need to step through the gears on Monday to avoid a series loss.