Steven Finn (3-27) reduced the hosts to 136-4 after England had set them 416 - the second highest chase ever - to win.
Earlier, Jonny Bairstow hit 79 - his best Test score for three years - and Joe Root 73 as England reached 326 in their second innings.
England are heavy favourites to earn a rare away win, but key batsman AB de Villiers remains unbeaten on 37.
He was reprieved six overs before the close when Bairstow missed a tough chance to stump him off the bowling of Moeen Ali.
Alastair Cook's men have won only one of their last 15 overseas Tests, but they have consistently outplayed the world's top-ranked Test side in this match.
The Proteas, meanwhile, have concerns over captain Hashim Amla, who again failed with the bat, and talismanic fast bowler Dale Steyn, who did not bowl after injuring his shoulder on the third day.
England resumed on 172-3, 261 runs ahead, looking for quick runs to set South Africa a challenging target, and in that context Bairstow's rapid innings was extremely valuable.
Playing with impressive fluency on a wicket on which scoring has generally been difficult and slow, the Yorkshire batsman struck nine fours and three sixes.
It was a significant knock from Bairstow, who is still seeking to establish himself as a permanent fixture in this England side ahead of rival wicketkeeper-batsman Jos Buttler.
But he could not record his maiden Test century, holing out off part-timer Stiaan van Zyl - who finished with 3-20 - as he unselfishly tried to accelerate with a declaration in prospect.
Earlier, Root added just 13 runs to his overnight score before edging Kyle Abbott to slip, continuing a pattern of failing to convert fifties into hundreds - the number four has just three centuries in 2015, despite having passed 50 13 times.
Ben Stokes' lean run with the bat continued as he edged Piedt to slip for five - the eighth time he has failed to pass five in his last 13 innings - but Chris Woakes contributed 23 in a useful cameo.
The hosts began well with the bat, with first-innings centurion Dean Elgar and Van Zyl cracking eight boundaries in the first nine overs as they raced to South Africa's first 50 partnership for the opening wicket in nine innings.
But Stokes removed Van Zyl just before tea, nipping a delivery between bat and pad.
Then it was over to Finn, who continued his fine wicket-taking form since being recalled to the side in the summer with a superb burst in the evening session.
First he induced the out-of-form Amla to chase a wide delivery and edge behind, then he had Elgar slash a full delivery to Root, who held a sharp catch at second slip.
And in the final over of the day, he ended the resistance of Faf du Plessis, producing a beautiful delivery which squared the batsman up and was edged to Cook at first slip.
Finn now looks a heavy favourite to retain his place ahead of Woakes if James Anderson returns from injury for the second Test, which begins in Cape Town on Saturday.
His career strike rate in Tests now stands at one wicket every 46.3 balls - second only to Steyn among active bowlers.
The one blemish in the evening session was a difficult stumping chance missed by Bairstow, which reprieved De Villiers on 33, when the ball turned sharply from outside off stump and bounced over middle.
BBC cricket correspondent Jonathan Agnew: "Jonny Bairstow batted well. He has been the only batter with any fluency in the match. He surprised people with his timing on this very slow pitch, which nobody has been able to get on top of.
"The problem is that he missed a stumping, and I suspect it might be that for which his contribution to this match is remembered.
"It wasn't straightforward, he only had a fraction of a second to see it, but Test cricket is the highest level and AB de Villiers is the key batsman.
"England have bowled well on a pitch that has become a bit benign, but when batsmen are looking to bat they are hard to prise out and you've just to got take every half chance."
Media playback is not supported on this device
England bowler Steven Finn on BBC Test Match Special: "It's nice to be contributing when you come back into the team. I felt good and felt I was threatening. It was important to break that stubborn partnership at the end. After tea we built more pressure and my wicket at the end was down to the hard work of all the bowlers.
"We are happy to have them four down. We would have liked more but can't complain about the position we are in and hopefully we can come back tomorrow and assert ourselves further.
"They still have some high quality players to come with Test hundreds to their names. Obviously De Villiers would be a key wicket to get because he's such a great player. Each evening the teams have been three or four down and not lasted much longer than an hour after lunch. If we can follow that we'll be happy but we're not expecting that and know we have to bowl like we did after tea today."
Ex-England opener Geoffrey Boycott on BBC Test Match Special: "England had a wonderful day. Root and the tail got us off nicely and then it was the Bairstow show. The timing of his shots were superb. He played the first and second innings perfectly and he was the only batsman that played with any fluency.
"Finn and Moeen have the gift of getting wickets. Finn gets four wickets a Test match - that's huge. He'd play in my team every time.
"De Villiers is a class apart, he just has so much time to play, has a wide range of shots and looks comfortable. Lesser players play and miss an odd time, but he doesn't look in any trouble and it's a surprise when he makes a mistake. He's the big fish they need to get tomorrow."
England need six wickets on the final day to complete victory in the first Test against South Africa in Durban.