Spinner Ravichandran Ashwin took four wickets as India dismissed South Africa for 275 to continue their dominance of the second Test in Pune.
Resuming on 36-3 in reply to India’s mammoth 601-4 orchestrated by Virat Kohli’s unbeaten 254, the tourists lost three wickets before lunch.
Skipper Faf du Plessis made a defiant 64, while number 10 Keshav Maharaj struck 12 fours in a career-best 72.
Ashwin took the final three wickets to secure a lead of 326 for the hosts.
World number one side India, who lead the three-match series 1-0 following a 203-run victory in Visakhapatnam, have yet to decide whether to enforce the follow-on.
Maharaj, whose previous highest score was 45, came to the crease in the 59th over when Du Plessis was caught at slip.
Batting with a bruised shoulder, the 29-year-old was dropped off his own bowling by Ashwin on 44 but compiled a stand of 109 for the ninth wicket with Vernon Philander before falling at leg slip in the 102nd over.
Ashwin dismissed last man Kagiso Rabada, a decision upheld after review, to record his 354th Test wicket and India, unbeaten in a home Test series since 2012, will look to complete a sixth win in their last eight matches.