AB de Villiers returned for South Africa, playing in his first international match after six months out with an elbow injury, and showed no signs of rust, striking two fours and three huge sixes in a 44-ball 63.
But the hosts were particularly profligate in the field, dropping five catches, including three in as many deliveries from one Wayne Parnell over, as Sri Lanka chased down 170 to win.
Niroshan Dickwella (68 off 51) was put down on two occasions, and made the most of the reprieves by hitting a 34-ball fifty, while Seekkuge Prasanna’s unbeaten 37 off 16 deliveries took the visitors to victory.
With the series tied at 1-1 going into the game, South Africa opted to bat first after winning the toss, but lost JJ Smuts (19) in the fifth over, bringing De Villiers to the crease.
He made a cautious start, with his first run not coming till his fifth ball faced, but gradually increased his range of strokes, hitting left-arm spinner Lakshan Sandakan for a straight six and pulling a short ball from Asela Gunaratne for another.
De Villiers shared in a 71-run stand for the second wicket with Reeza Hendricks (41 off 34), and brought up his ninth T20I fifty off 35 balls.
But South Africa lost their way in the second half of their innings and were struggling at 135-5 when soon after he again cleared the boundary with another pull shot, off Isuru Udana, De Villiers fell to start the 18th over.
Mangaliso Mosehle smashed three sixes in the final over to tally an unbeaten 32 off 15 which lifted the home side’s score.
But South Africa shelled two early chances in Sri Lanka’s reply – Upul Tharanga (20) and Dinesh Chandimal (5) put down, although the drops didn’t prove too costly as both departed soon afterwards.
The same could not be said for the next three drops, which came off consecutive deliveries in a bizarre seventh over from Parnell, as Dickwella and Dhananjaya de Silva (19) would put on 71 together for the third wicket.
Imran Tahir (3-18) dismissed both in the 16th over to seemingly end Sri Lanka’s hopes of victory, before 19 runs were then taken from Parnell’s next.
Prasanna struck two of his three sixes in that over, and ultimately saw the visitors to victory, with the support of Asela Gunaratne (11no) – who was somewhat premature in celebrating the win, ripping a stump out the ground when the scores were only tied with his boundary in the final over.
He would, however, hit the winning run a ball later, off the penultimate delivery of the match, confirming Sri Lanka’s series victory.
South Africa and Sri Lanka meet again in a five-match ODI series, starting in Port Elizabeth on Saturday. (Courtesy Sky Sports)