Skipper Mahela Jayawardene (51) and Kaushal Lokuarachchi (69) added 75 and 104 respectively with Sangakkara as Sri Lanka bid to prevent the hosts winning their first-ever ODI series with the sides tied at 1-1.
The hosts' hopes were given an early lift when a double strike from Mashrafe Mortaza removed Sanath Jayasuriya and Upul Tharanga to leave Sri Lanka on 17 for 2.
But Sangakkara and Jayawardene steadied the boat with a solid stand before Jayawardene, who faced 56 balls and hit eight fours, was caught and bowled by Mohammad Rafique.
Lokuarachchi continued the momentum with three enormous sixes in his 57-ball cameo before he was bowled by Rafique.
Sangakkara reached his fifth one-day century when Rafique claimed his third victim as he ended the wicketkeeper's 125-ball vigil by knocking over his stumps.
Tillakaratne Dilshan (22), Farveez Maharoof (27no) and Chamara Kapugedera (16) added valuable late runs.
Sri Lanka won the opening match of the series in Bogra on Monday before Bangladesh recorded a four-wicket win, only their 11th triumph in 117 one-day matches, in Wednesday's second match, also in Bogra.