AB de Villiers and Rohit Sharma enhanced personal reputations with brilliant centuries but timely interventions by South African bowlers secured a five-run victory for the visitors over India in the first one-day match on Sunday.

De Villiers' unbeaten 73-ball century provided the late swing as South Africa posted 303 for five, the highest team total at the Green Park Stadium, after deciding to bat first.

Imran Tahir's turned the match on it's head while claiming two wickets in his final over and paceman Kagiso Rabada dismissed another two Indian batsmen in two deliveries in the final over to put South Africa 1-0 up in the five-match series. It was the perfect KO punch.Team India required 22 runs of the last two overs with five wickets in hand and Dale Steyn conceded 11 before 20-year-old Rabada claimed back-to-back wickets to restrict the hosts to 298 for seven.

"I thought Imran Tahir first of all changed the game and gave us a chance. And lot of credit to Dale and Kagiso. The youngster has proved to be quite the handful and he has got a bright future," De Villiers, who was adjudged man-of-the-match for his unbeaten 104-run blitz, told reporters.

Containing De Villiers is one of the toughest jobs in international cricket and India were severely handicapped when their strike bowler Ravichandran Ashwin left the field after sending down only 4.4 overs. Ashwin struck in his first over to dismiss Quinton de Kock but Faf du Plessis (62) and Hashim Amla (37) shared a half-century stand to give SA a good platform.

De Villiers did not hit a boundary in the first 33 balls he faced but was unstoppable when he finally got going. The right-hander clobbered his sixth six off the final ball of the innings to bring up his 21st ODI century as South Africa plundered 109 runs from the last 10 overs.

When India came out to bat, Sharma -- who scored exactly 150 -- added 149 runs with Ajinkya Rahane (60) and the hosts looked on course to chase down the target without any fuss. Sharma hit six sixes and 13 boundaries before giving a return catch to Tahir who dismissed Suresh Raina in the same over.

India captain Mahendra Singh Dhoni (31) struggled throughout his scratchy knock and fell in the final over. Off-spinner Harbhajan Singh will join the Indian squad as Ashwin's cover before the second match in Indore on Wednesday.