Perth: Nathan Coulter-Nile and George Bailey hand Australia a 1-0 lead in the five match ODI series.
Australian captain Michael Clarke re-injuring his troublesome hamstring.
The skipper made 11 from 20 balls before falling to arch-rival Dale Steyn, and will now have scans on Saturday to determine the extent of the damage.
South Africa were set 301 to win on a fast WACA Ground wicket thanks to acting-captain George Bailey (70 off 75) and David Warner (46 off 49), and looked in complete control when AB de Villiers (80 off 76) and David Miller (65 off 65) combined for a 126-run stand.
But man-of-the-match Nathan Coulter-Nile (4-48) and Mitchell Johnson (2-38) proved too hot to handle on their home turf, handing Australia a 1-0 series lead before the two teams square-off again on Sunday at the same venue.
Earlier, Vernon Philander produced false strokes from both openers early on, before Steyn produced what he and umpire Simon Fry thought was the first breakthrough of the morning, but Aaron Finch, in consultation with opening partner David Warner, rightly chose to review the lbw decision that proved to be flying high and wide over leg stump.
After a cautious beginning, the pair upped the ante when Warner belted two sixes off Philander and Morkel, then the pair ambushed leg-spinner Imran Tahir for 15 from his first over.
But after conceding a dozen runs two overs earlier, Ryan McLaren's fantastic effort in the outfield - running in and diving forward to take a catch centimetres off the ground - sent Warner on his way for 46 (49) to give Philander and South Africa a much needed wicket.
Two balls later Finch followed Warner back to the pavilion, caught behind to fall for 35 (40) and leave Australia 94 for 2 from 15 overs.
After a few probing overs, first blood would be taken by the Proteas paceman when Clarke gloved a hurried hook shot that ballooned to wicketkeeper Quinton de Kock, leaving the Aussie skipper to walk off as Steyn erupted at getting his heated rival.
Bailey had his fair share of luck, let off twice in the space of four balls, both regulation chances to first David Miller at point, then Imran Tahir off his own bowling.
And just when catches were going down like water, Watson's sweep shot found Morkel's bucket-sized hands at short fine-leg to depart for 13 (27) to leave Australia teetering at 130 for 4 in the 26th over.
The rapid start set by Warner and Finch felt like an age ago when Mitch Marsh's bright innings ended when he missed Philander's off-cutter to go for 10 (15) and by the 30th over, Australia had lost 5-40.
Amid the Bailey-Matthew Wade revival, news swept across the press box, then the world, that Clarke had re-injured his hamstring while batting and would take no further part in the match.
Now the acting captain, Bailey's incredulous run of good luck continued, dropped twice more – both difficult chances by Philander and Farhaan Behardien – the latter joining Clarke in the casualty ward after jarring his shoulder diving forward in similar fashion to McLaren's super grab to dismiss Warner.
Wade (35 off 40) would fall in the dying stages, caught in the deep to see Philander bag four, but Maxwell, through innovation, unorthodox stroke play and a fair slice of luck, took 17 off Steyn's penultimate over, eventually falling for 29 off 19 balls.
But the damage had been done as Johnson (13 not out off 8) guided Australia to a commanding first innings score of 300 for 8.
Australia fired early with the ball. Johnson has spoken previously about how he gains confidence when he scores run with the bat, and the West Australian was brimming with the stuff when he removed de Kock in the third over for 2 (7), and then Hashim Amla for 8 (13), with wicketkeeper Wade making no mistake on both counts.
Coming off ODI scores of 106, 126 and 96 against Australia, du Plessis entered the run chase knowing he'd had success against his opponents and their pace spearhead, and with Behardien began rebuilding the Proteas innings.
The pair had seen off Johnson and started to put the pressure back on the Australians, but Behardien's skied pull shot off Coulter-Nile was caught in the deep by Finch to bring FDP and ADV together at 53 for 3 in the 12th over.
But de Villiers was still there, and despite a brief scare with an overturned lbw decision, the Proteas captain looked untroubled, teaming up with Miller to race to their fifty partnership off 48 balls and keep in close proximity to the required run rate.
Coulter-Nile was called back on by Bailey to break up the dominant South Africans and almost answered his captain's request, but Finch at fine-leg couldn't reach Miller's loose hook shot at deep long-leg.
De Villiers launched Maxwell into the prevailing sea breeze to bring up his half-century, and when Miller's edge off Johnson fell short of first-slip, the left-hander also raised the bat and the pair's hundred partnership to 101 off 102 balls.
Coulter-Nile would take the next over and strike immediately, removing Miller caught at mid-on for a run-a-ball 65, then McLaren for naught to a nasty short ball that took a referral to confirm contact with the glove through to the waiting Wade.
The visitors had lost 13 for 4 in the space of 22 balls during the batting power play, and with Steyn and Morkel at the crease, Bailey recalled spearhead Johnson to dish out some punishment to his opposing fast bowlers.
Coulter-Nile collected Steyn's wicket to finish with career-best figures of 4-48. Maxwell picked up the last wicket, Tahir for 22 (22) to seal the win with 11 balls remaining and head into Sunday's clash 1-nil up.
Earlier, South Africa have won the toss and have opted to field
Australia: David Warner, Aaron Finch, Shane Watson, Michael Clarke (Capt.), George Bailey, Mitchell Marsh, Glenn Maxwell, Matthew Wade (wk), Mitchell Johnson, Nathan Coulter-Nile, Josh Hazlewood
South Africa: Hashim Amla, Quinton de Kock (wk), Faf du Plessis, AB de Villiers (Capt.), Farhaan Behardien, David Miller, Ryan McLaren, Vernon Philander, Dale Steyn, Morne Morkel, Imran Tahir
Australia - 300/8 (Bailey 70, Philander 4-45)
South Africa - 268 (de Villiers 80, Miller 65, Coulter-Nile 4-48)
Result - Australia won by 32 runs
MOM - Nathan Coulter-Nile (Australia)