Quinton de Kock was again in magical form with the bat, striking 65 off 22 deliveries, including the fastest ever T20I half-century by a South African, before Rassie van der Dussen (43*) steered the hosts towards victory.
However, needing three off the last two balls, they were undone by Curran, who dismissed Dwaine Pretorious (25) lbw and then had Bjorn Fortuin caught for a duck by Adil Rashid attempting a ramp.
England went with an unchanged side, meaning Jos Buttler at the top of the order once more, but he nicked off for two to add further fuel to the debate about his best use in the side ahead of the World Cup in October.
That united Jason Roy (40) and Jonny Bairstow (35) in the middle, rebuilding with assistance from captain Eoin Morgan (27), but when Joe Denly was bowled by a slower ball from Andile Phehlukwayo for one England were struggling on 125-5 with fewer than five overs to come.
Moeen took centre stage, his bludgeoning knock including four sixes and three fours at a strike rate of more than 350.00, while Stokes accelerated late on as England finished 204 for seven.
De Kock and Temba Bavuma put on 92 for the first wicket but Mark Wood and Chris Jordan took two wickets apiece to help slow South Africa to 158-5 after 16.4 overs.
Pretorious and van der Dussen fought back to leave 15 needed off the final over, and when the former struck a four and a six they looked as good as home, but Curran responded to level the series and set up a decider in Centurion on Sunday.