Marlon Samuels and Darren Bravo were at the crease with the West Indies requiring 144 more runs to win from the remaining 16 overs with seven wickets in hand at Sophia Gardens.
West Indies lost the important wicket of Devon Smith (30) trapped leg before by left-arm spinner Robin Peterson just before the rain halted the proceedings in the 15th over.
West Indies lost Johnson Charles (16) early into their run chase as he was caught by wicketkeeper AB de Villiers at short third man off Dale Steyn.
Gayle scored 27-ball 36 with the help of five fours and a straight six diwn the wicket.
More From This Section
Earlier, opener Colin Ingram struck a fluent half-century while David Miller played an unbeaten cameo of 38 as South Africa posted a formidable 230 for six in a rain-curtailed match.
South Africa's fifth-wicket pair of Miller and Faf du Plessis (32-ball 35) put on display some sensational strokeplay at the business end of the innings and added 68 runs in just 48 deliveries to put their side in the driver's seat.
Miller's unbeaten knock of 38 was laced with three huge sixes and a four while Plessis decorated his useful innings with three fours and a six.
Ingram hit 63-ball 73 laced with six fours and two sixes while skipper Villiers hit a 25-ball 37 after South Africa were invited to bat first under overcast conditions.
The match started three hours and 15 minutes late than the scheduled toss due to inclement weather, reducing it to a 31-over-a-side encounter.