Mumbai: AB de Villiers smashed 29 off an over before South Africa were given a scare in a 37-run win over Afghanistan at the World Twenty20 at Wankhede Stadium in Mumbai on Sunday.
De Villiers took Rashid Khan for four sixes and a four in his 29-ball 64 to propel the Proteas to 209-5.
South Africa were worried by Afghanistan opener Mohammad Shahzad, who hit five sixes in a 19-ball 44.
But after he was bowled by Chris Morris, who took 4-27, Afghanistan fell away to 172 all out.
South Africa, beaten by England in their opening match, are still to face West Indies and Sri Lanka in a Group 1 that could yet be decided on net run-rate.
Afghanistan will be eliminated if they lose to England on Wednesday, but the only nation outside of Test cricket still left in the competition again showed they can compete at this level.
De Villiers has got form for devastating hitting in white-ball cricket, holding the record for the fastest century and 150 in one-day internationals.
Here, with the Proteas in danger of falling short of a winning total, he dished out some brutal treatment to 17-year-old leg-spinner Rashid.
It was the joint-fourth most expensive over at the World T20, with De Villiers sweeping Mohammad Nabi for another six from the first ball of the following over before holing out on the mid-wicket fence.
In all, the Proteas took 71 off the final four overs to reach the sixth-highest World T20 total.
South Africa already had one bad experience at a run-filled Wankhede Stadium, conceding 230 to lose to England on Friday.
In response, they omitted Dale Steyn for David Wiese, then saw new-ball pair Kagiso Rabada and Kyle Abbott flayed by the unorthodox Shahzad.
Swinging and swiping, Shahzad heaved four of his five sixes over the leg side, taking Afghanistan to 47-0 from only three overs.
However, he was eventually contained by the control of the excellent Morris and bowled at the end of the fourth over.
From there regular wickets, including two each for Rabada, Abbott and leg-spinner Imran Tahir, saw Afghanistan bowled out off the final ball of the innings.
Brief scores
South Africa - 209 for 5 (de Villiers 64, de Kock 45, du Plessis 41)
Afghanistan - 172 (Shahzad 44, Morris 4-27, Imran 2-24)
Resul - South Africa won by 37 runs
Points - South Africa 2, Afghanistan 0
MOM - Chris Morris (South Africa)