A career-best 129 by Dean Elgar added to a typical free-flowing Quinton de Kock innings, helped the Standard Bank Proteas seize the initiative during the latter part of the opening day of the second Sunfoil Test against Sri Lanka at PPC Newlands in Cape Town on Monday.
The hosts reached stumps on 297/6 on a day when batting seemed more difficult than bowling, with the tourists winning the toss and opting to field first.
They made inroads throughout, but struggled to claim the key wicket of Elgar until late in the day and only after the plucky left-hander had already batted for just over six hours, faced 230 balls and struck 15 fours.
He proved to be the rock for the South Africans as he notched up the sixth career century for his country and surpassed his previous best 127 made against Australia in Perth during November.
Along with de Kock, the pair shared in a 103-run, sixth wicket stand that helped shift control of the game after their side had looked in a bit of trouble on 159/5 at a stage just after lunch.
De Kock, who passed 1000 Tests along the way, ended the day unbeaten on 68 (90 balls, 7 fours), while Elgar eventually fell just under half-an-hour before the close, having watched five of his fellow top-order colleagues fall across him.
Stephen Cook and JP Duminy both fell for ducks, while there were starts for Hashim Amla (29) and captain Faf du Plessis (38). Temba Bavuma made 10.
There was also one crucial reprieve for De Kock when he was on 58 and the total 270/5.
He was given out leg before wicket by umpire Aleem Dar, but reviewed the decision - more in hope rather than in confidence - and it proved a useful gamble as ball-tracker showed the delivery sliding down leg side.
Nightwatchman Kyle Abbott was unbeaten on an impressive 16 by the close, while Lahiru Kumara was the pick of the bowlers was 3/86.