Dasun Shanaka hit a quickfire 65 as Sri Lanka blasted 306-7 off 39 overs in the rain-shortened fourth ODI against South Africa here on Wednesday.
Thisara Perera made an unbeaten 51 and Kusal Perera also hit 51 as the home side punished the South Africa bowlers.
Sri Lanka is seeking consolation in the series which it has already lost with defeats in the first three games.
Rain delayed the start of the game which was eventually cut from 50 overs to 39.