Sri Lanka 123 for 7 (Sangakkara 37, Thisara 35*, Mortaza 2-29) beat Bangladesh 120 (Sabbir 26, Malinga 3-20) by three wickets
Scorecard and ball-by-ball details
Mashrafe Mortaza's first tilt at captaincy started and finished by falling at the crease in 2009 and 2010. Now, as a stopgap captain in place of Mushfiqur Rahim, he has made the most imaginative attempt by a Bangladeshi captain. With only 120 runs to defend, Mashrafe rotated his bowlers wisely, but in the end, Bangladesh went down on the final ball.
With two needed off the last delivery, Sachithra Senanayake smacked a short delivery from Farhad Reza for four. It was perhaps a cruel end for the bowler, as Reza had bowled five good deliveries before that when he started off with nine required off the final over. It was a lucky break for Sri Lanka, who have now won the series 2-0, and head to Dhaka for the ODI leg of the tour full of confidence.
In the tense finish, Senanayake and Thisara Perera, surprised with their lack of boundaries - the final six overs had only three fours - but they scampered the ones and twos, winning the game with a 27-run stand from 3.2 overs.
Bangladesh were tremendous in the field, particularly Mashrafe who didn't let the Sri Lankan top-order settle as he kept using bowlers for just one over each from the start.
Arafat Sunny gave just eight runs from his two overs and even picked up a wicket, as did Rubel Hossain, Shakib Al Hasan and Mahmudullah. Mashrafe himself snared two scalps.
Kusal Perera and Dinesh Chandimal fell by missing reverse-sweeps while Tillakaratne Dilshan was bowled when looking to cut. Mashrafe's two-wicket over, the tenth of the innings, turned the game towards Bangladesh. He removed Angelo Perera with a fast off-cutter, and then took out Angelo Mathews with one that went out, inducing an edge.
Nuwan Kulasekara was run-out after he was turned back by the non-striker, but Kumar Sangakkara kept the runs flowing and eventually ended as the team's highest run-getter with 37. However, in the 17th over in which he had taken 11 runs, Sangakkara found short third-man where Tamim Iqbal took a smart catch.
When Bangladesh decided to bat, Kulasekara's two wickets went by unnoticed. Tamim Iqbal and Farhad Reza went after him, faltered and gave catches. But the catches Kulasekara took, dispirited Bangladesh's aggression. Lasith Malinga took three wickets, while Senanayake finished with 2 for 11.
Sri Lanka had started the innings with a dropped catch. Malinga could only touch the ball over his head at short fine-leg, off the third delivery of the opening over. But just like Shamsur Rahman had done the last time when a spinner opened the bowling in a T20 against Bangladesh, he dinked Dilshan's poor fifth delivery to midwicket, getting easily caught.
Tamim Iqbal followed suit in the next over, holing out to third man, with his running flash outside off-stump making for poor shot selection. Sometimes, Tamim goes back to his early days in international cricket when he could charge any bowler. But with so much knowledge of his batting being ferried around, some of these shots have become too predictable.
Anamul Haque kept the holiday crowd entertained when he slammed two fours and two sixes off Dilshan's next over. Both sixes were through midwicket, as Anamul attacked confidently. Shakib was giving him good support at that stage, but the partnership was brought to an end by a stunning catch.
Kulasekara ran hard from mid-on as Shakib skied towards long-on, the fielder continually running until he caught up with the dipping ball. The impact of his dive took him close to the boundary, but he held on and stayed within bounds. Kulasekara would also have a large say about the last Bangladesh wicket, when he dived in from deep cover to catch Sabbir Rahman's slice.
Exactly two overs later, Kusal Perera tried to better Kulasekara at deep midwicket, when he intercepted Anamul's slog sweep with a tremendous effort at the boundary. He was mid-air when he dived to his right.
Only a small section of the crowd, adorned in the deep blue of Sri Lanka, cheered heartily as the rest of the 15,000 remained largely silent. Nasir Hossain and Farhad Reza gave easy catches to cover, while Mahmudullah was a victim of poor calling from the debutant Sabbir Rahman, who was the team's top-scorer with 26.
Ultimately, the hosts were left ruing a second consecutive last-ball defeat in the space of three days.
Mohammad Isam is ESPNcricinfo's Bangladesh correspondent. He tweets here