Chasing a victory target of 245, Bangladesh were on course of a victory, with opener Tanzid Hasan Tamim and Najmul Hossain cutting through Sri Lankan attack in surgical fashion to help the side reach 100-1 in 16.2 overs.
The rot began with the dismissal of Shanto who went for an unlikely second run to trap himself in run-out for 23.
The leg-spin of Wanindu Hasaranga and the off-spin of Kamindu Mendis then appeared into the stage. And they demolished the visiting side in just 23 balls. In that manic 23 balls, Bangladesh lost six wickets with the both bowlers claiming three evenly to completely shatter the visitors' any of winning the game.
Jaker Ali Anik then delayed the inevitable with 64 ball-51, featuring four fours and as many sixes. He shared 62 runs with the last two batters-Tanvir Islam (5) and Mustafizur Rahman (0 not out off 12) before being dismissed by Hasaranga.
Hasaranga eventually finished with 4-10 as Bangladesh were dismissed for 167 in 35.5 overs.
Skipper Charith Asalanka who hammered 106 led Sri Lanka to 244 all out in 49.2 in a one-man show after opting to bat first.
He stitched two important partnerships-60 with Kusal Mendis who made second-best 45 and 64 with Janith Liyanage (29) to help the side edge closer to 250.
Bangladesh began the chase in emphatic fashion with Parvez Hossain Emon who made the ODI debut, launching Asitha Fernando for boundary twice in the first over.
His fellow opener Tanzid Hasan Tamim also started with a boundary but saw the fun of Emon short-lived as he top-edged a short delivery of Fernando to wicket-keeper Kusal Mendis for 13.
But Tanzid, along with Shanto kept hitting until he became the part of that infamous collapse. He was undone by an excellent catch of Janith Liyanage after trying to hit Hasanranga out of the park.
Tanzid top-scored for the side with 61 ball-62, an innings laced with nine fours and one six.
Fast bowler Taskin Ahmed came back with a bang by claiming 4-47 as Bangladesh bundled out to a total that was within their reach.
In an otherwise a pretty flat deck, Taskin who just returned to the squad after recovering from an injury roared exceptionally to deny Sri Lanka a big total despite its captain Charith Asalanka's scintillating 106.
Taskin scythed down Sri Lanka's top order in his first spell by removing opener Nishan Madushka and ever dangerous Kamindu Mendis. In between Tanzim Hasan Sakib had inform opener Pathum Nissanka caught by Liton Das for duck, reducing Sri Lanka to 29-3 in seventh over as they opted to bat first.
Taskin bowled a maiden over and even could have got the wicket of Nissanka also as the opener found him in wanting against the fast bowler. However, Tanizm reaped the rewards of Taskin's good work by dismissing Nissanka.
Kusal Mendis scored second best 45 for Sri Lanka and added 60-run with captain Asalanka to bring Sri Lanka back in the contest.
Kusal dominated the partnership by attacking the Bangladesh bowlers in precision. Left-arm spinner Tanvir Islam trapped him leg-before for his maiden wicket as Kusal was denied a half-century by five runs.
But Asalanka was calm like cucumber. Amid the tumbling of the wickets, he stayed focused on his job and counterattacked in style to keep the scoreboard flowing.
Janith Liyanage gave him the required support as the duo looked well set to take the total out of reach for Bangladesh.
The visiting side got the breakthrough from an unlikely source. With the key bowlers failing to break the partnership, captain Mehidy Hasan Miraz played a gamble by calling up the occasional spin of Najmul Hossain Shanto.
And the gamble paid off as Shanto had Liyanage holing out to long on for 29, ending the 64-run partnership.
Asalanka raised his second ton against Bangladesh and overall his fifth off 117 balls, guiding a delivery of Tanzim Hasan Sakib for a single.
Milan Rathnayake and Wanindu Hasaranga scored 22 each to give the captain some support. However, Asalanka was the ninth batter out in the first ball of the last over, when Tanzim got the better of him to end with 3-46.
Asalanka struck six fours and four sixes in his 123 ball-106.
His dismissal effectively ended Sri Lanka's chance to go past 250-run mark but the total they put up was enough for a facile victory, reports BSS.