Seamer Thisara Perera (4-42) bagged a hat-trick as Sri Lanka, who scored 243-8, bowled Pakistan out for 199 despite a 113-run stand for third wicket between opener Azhar Ali (81 not out) and skipper Misbah-ul-Haq (57).
Thisara Perera Hat-Trick + Brilliant Run Out against Pakistan
Kumar Sangakkara top-scored for Sri Lanka with a 130-ball 97 while off-spinners Mohammad Hafeez and Saeed Ajmal, and paceman Sohail Tanvir each bagged two wickets for Pakistan in the day-night match.
Pakistan won the opening one-dayer by six wickets and Sri Lanka won the second game by 76 runs in Pallekele, while the third match was abandoned due to rain in Colombo on Wednesday.
The fifth one-dayer will be played in Colombo on Monday.