Bad light robbed Australia of a four-day victory in Durban as the tourists left the field just one wicket away from a commanding win in the first Test.
The match looked destined for a fifth day when brilliant century-maker Aiden Markram (143) and Quinton de Kock (81 not out) batted out most of the final session before Mitchell Starc captured three wickets in the 80th over to put Australia on the brink of victory.
But with sun blocked out by heavy cloud cover over Kingsmead, Australia were forced to bowl their spinners until the match officials deemed it too dark to play on.
It means both sides will come back on Monday with South Africa 9-293, still 124 runs short of their victory target.
Before darkness descended on Durban, for the first time in the series tempers flared as David Warner and Nathan Lyon combined to run out AB de Villiers without scoring before Starc got lippy with a gutsy Theunis de Bruyn.
A collapse of 4-20 in the morning session put Australia on course for a quick finish, but the innings from Markram, de Bruyn (36) and de Kock showed the fighting qualities the Proteas lacked in their first dig.
Australia added 14 runs to their overnight tally before Cummins dragged on Keshav Maharaj to give the spinner his ninth wicket for the match and end the tourists’ innings on 227 just 15 minutes into the day’s play.
Set 417 to win, the Proteas needed to break their all-time highest successful run chase – the 4-414 they scored against Australia in December 2008 – but their chances of re-writing history went south early in the pursuit.
Nursing an injured pinky finger that was dislocated taking a catch late on day three, Dean Elgar was undone by Starc’s first bouncer directed at the left-hander, a rising delivery that took the shoulder of his bat on the way through to keeper Tim Paine to trigger the top-order collapse.
Elgar’s wicket brought Hashim Amla to the crease and Josh Hazlewood back into the attack to bowl to the batsman he had dismissed in each of the five innings he'd bowled at him before Lyon broke the streak in the first innings.
Order was restored from the 11th ball the veteran faced from Hazlewood, who might have passed out with exhaustion had his thunderous appeal for lbw gone on any longer.
Amla reviewed but the ball was clipping leg stump to give the Australians a second opportunity to celebrate.
The party was only getting started. Seven balls later de Villiers was out, sent back in a mix up with Markram as the visitors executed a textbook run-out through fielder Warner and bowler Lyon, and what followed next could land the Australian pair in hot water.
As Lyon whipped off the bails and raced to join his jubilant teammates, he dropped the ball which grazed the torso of de Villiers, who was outstretched and horizontal next to the pitch at the end of his desperate dive.
By the time Lyon reached the huddle, Warner had already given Markram an almighty spray for running out South Africa’s best batsman for a golden duck and been mobbed by his comrades.
The banter continued as Markram and Faf du Plessis took guard and it wasn’t long before the Proteas captain was back in the pavilion, bowled through the gate by a rocket from Cummins that sent the off-stump cartwheeling halfway to the boundary.
De Plessis’ wicket was the end of the collapse but the match came to life once again after lunch when No.6 Theunis de Bruyn edged Starc high between ‘keeper and first slip with neither player attempting a catch.
Starc reminded the batsman, in not so many words, how fortunate he was to have survived, and the advice from the left-armer continued for the remainder of that over and the next.
De Bruyn was up to the task and like a red rag to a bull, each time the batsman flayed a reverse-swinging half-volley to the rope the chat from the bowler intensified.
The mid-session drinks break cooled things down and two overs later the ball was changed by the standing umpires, who drew a cross on the discarded Kookaburra with a cross on either side on of the flat seam.
The new old ball did the trick less than five overs later when de Bruyn’s stand came to end as Hazlewood extracted an outside edge through to Paine, who happily accepted the opportunity.
It ended an 87-run stand for the fifth wicket, with Markram proving unflappable as he moved closer to a third Test ton in front of a swelling crowd that came alive during the Starc-de Bruyn bout.
However, the biggest cheer of the day was reserved for Markram, who received a standing ovation after he scampered through for a risky single to bring up three figures.
While Markram was all grit and defiance, de Kock was at time toying with the Australians with the audacious, clean-striking that has seen him compared to perhaps Test cricket’s greatest wicketkeeper-batsman, Adam Gilchrist.
Like Gilchrist, de Kock was savage on anything short, cutting Lyon with ease and picking off anything on his legs from the quicks as his partnership with the opener approached 150.
Smith burnt both Australia’s reviews trying to remove the top-order barnacle – an lbw off Lyon that was impacting outside off-stump and a catch at slip off Cummins that was all helmet and no glove – but after 339 minutes at the crease, the visitors had their man.
With the second new ball in sight, Mitch Marsh was operating to give the fast bowlers a rest but it was the allrounder who provided the breakthrough when Markram’s cut was held by Paine, who was up to the stumps to complete the brilliant catch.
As if a switch had been flicked, in almost an instant the sunshine that drenched Kingsmead disappeared, replaced by the same gloomy conditions that has seen play ended early in two of the three days.
The match looked likely to stretch into a fifth day until Starc, with a reverse-swinging ball at his disposal, had Vernon Philander caught behind and castled Maharaj and Kagiso Rabada with consecutive deliveries to finish the over on a hat-trick.
But with the artificial light from the light towers taking over, Smith was forced to bowl his spinners, which included himself, or the umpires would call play off.
With five overs still to go, the umpires read the light meter again and that was that, the artificial light proved too dominant and the preparations for a day five began in haste.
AUSTRALIA XI: David Warner, Cameron Bancroft, Usman Khawaja, Steve Smith (c), Shaun Marsh, Mitchell Marsh, Tim Paine (wk), Mitchell Starc, Pat Cummins, Josh Hazlewood, Nathan Lyon.
SOUTH AFRICA XI: Aiden Markram, Dean Elgar, Hashim Amla, AB de Villiers, Faf du Plessis (c), Quinton de Kock (wk), Theunis de Bruyn, Vernon Philander, Kagiso Rabada, Keshav Maharaj, Morne Morkel.
Qantas tour of South Africa
South Africa squad: Faf du Plessis (c), Hashim Amla, Temba Bavuma, Quinton de Kock, Theunis de Bruyn, AB de Villiers, Dean Elgar, Heinrich Klaasen, Keshav Maharaj, Aiden Markram, Morne Morkel, Wiaan Mulder, Lungi Ngidi, Vernon Philander, Kagiso Rabada.
Australia squad: Steve Smith (c), David Warner (vc), Cameron Bancroft, Pat Cummins, Peter Handscomb, Josh Hazlewood, Jon Holland, Usman Khawaja, Nathan Lyon, Mitchell Marsh, Shaun Marsh, Tim Paine, Jhye Richardson, Chadd Sayers, Mitchell Starc.
Warm-up match: Australia beat South Africa A by five wickets. Report, highlights
First Test Kingsmead, Durban, March 1-5. Live coverage
Second Test St George's Park, Port Elizabeth, March 9-13. Live coverage
Third Test Newlands, Cape Town, March 22-26. Live coverage
Fourth Test Wanderers, Johannesburg, March 30-April 3. Live coverage