England bowlers failed to defend 342 as Temba Bavuma’s century helped South Africa win the second ODI to clinch the series 2-0 with one to play.
Jos Buttler’s unbeaten 94 balls from 82 were the backbone of England’s tally, while Harry Brook netted an impressive 80.
But England’s attack struggled to break through at key moments as South African skipper Bavuma’s 109 from 102 balls laid the groundwork for the chase.
David Miller’s unbeaten 58 saw the hosts cross the line with five balls and five wickets to spare as they completed their third highest ODI chase.
It could prove to be a crucial win in the Proteas’ bid to secure automatic World Cup qualification later this year via the ICC Super League.
Asked to bat first, England recovered from a hostile bowling spell, which left them 33-2, thanks to crucial shots from Brook and Buttler.
Moeen Ali played a useful hand with 51-45 as he shared a 106-run stand with Buttler for the fifth wicket before the South African bowlers rallied.
England were pushed back in the business end of the innings, although Buttler and Sam Curran (28) provided an explosive finish, hitting 30 on the final two overs.
Bavuma played with freedom en route to his 90-ball century but, having battled cramp in the latter part of his innings, was knocked down by Curran.
Rassie van der Dussen (38) and Aiden Markram (49) played useful supporting roles, bolstered by a compound shot from Miller on 37 balls as he sealed victory with a six on the first ball of the final.