India were limited to 201 runs in reply to South Africa's 489 on day three in Guwahati as Jansen continued his star turn with bat and ball.
The Proteas then extended their lead on Monday by opting not to enforce the follow-on, Aiden Markram (12) and Ryan Rickelton (13) putting on 26 in eight overs before stumps.
Jansen's burst was the third-best bowling figures for a South African pacer in India, and the fourth best for a left-arm pacer overall. Simon Harmer also took 3-64 as the top of the Indian order collapsed either side of tea.
"There is nice pace and bounce in the wicket," Jansen said. "The spinners did a good job early on and I am lucky to cash in. We thought we were going to field for at least two days. I took off steam last evening (after missing a Test hundred), and today was as about doing a job for my team."
Opener Yashasvi Jaiswal was India's top scorer with 58 runs with Washington Sundar adding 48.
India's Atleast Jaiswal and Lokesh Rahul put up a fight in the first hour of play by adding 65 runs off 129 balls before Keshav Maharaj (1-29) struck in the 22nd over to have Rahul caught at slip.
Harmer dismissed Jaiswal in the 33rd over with a delivery that bounced a little more than the opener expected, Jansen taking a low catch at backward point. Sai Sudharsan was caught at midwicket two overs later playing a rash stroke to Harmer.
Jansen struck for the first time before tea, getting Dhruv Jurel out for an 11-ball duck after being promoted to No.4 in the absence of the injured Shubman Gill.
India slid from 1-95 to 4-102 in the space of 19 deliveries before the tea break. It didn't get any better in the second session as stand-in skipper Rishabh Pant was caught behind almost immediately.
Nitish Reddy (10) was caught at gully when the bounce from Jansen surprised him and Markram took a stunning one-handed catch. Jadeja was then caught in the cordon for six runs as Jansen's burst of four wickets left India struggling at 7-122.
Overall, across the tea break, India had lost six wickets for 27 runs in just 11.1 overs.
Sundar and Kuldeep Yadav then brought a bit of stability by scoring 72 runs. But Harmer got the breakthrough in the 79th over, with Sundar caught at slip. Jansen then returned to dismiss Yadav and Jasprit Bumrah quickly and finish off a hapless Indian batting performance.
Jansen had scored 97 runs in South Africa's first innings – only the third visiting player to achieve the double of 50 runs and a five-wicket haul in the same Test in India.
World Test champions South Africa lead the two-Test series after winning the opener in Kolkata by 30 runs. The Proteas are chasing a first Test series win on Indian soil since 2000-01.