The hosts raced to 129-3 in 23.3 overs after Shoriful Islam's career best 4-21 helped them bowl out Afghanistan for 126
Liton Das top-scored with 53 not out as Bangladesh defeated Afghanistan by seven wickets to avoid a series whitewash in Tuesday's third and final one-day international in Chittagong.
The hosts raced to 129-3 in 23.3 overs after Shoriful Islam's career best 4-21 helped them bowl out Afghanistan for 126 in 45.2 overs.
Tail-ender Azmatullah Omarzai offered some late resistance for Afghanistan to top-score with 56, his maiden ODI fifty.
Left-arm seamer Fazalhaq Farooqi gave Afghanistan a glimmer of hope, bowling out Naim Sheikh for a duck and Najmul Hossain for 11.
Liton and Shakib Al Hasan put on 61 runs for the third wicket to steady the innings and bring Bangladesh back into control.
Shakib fell to Mohammad Nabi after making a run-a-ball 39, but Liton, who struck three fours and two sixes in his 60-ball innings, took Bangladesh home.
Young Towhid Hridoy hit the winning boundary off Zia-ur-Rehman to stay unbeaten on 22.
The tourists earlier won the toss and elected to bat first, but never managed to get their innings going.
Shoriful struck early after taking the field for the first time this series, dismissing Ibrahim Zadran for one and Rahmat Shah for a duck in the third over.
Rahmanullah Gurbaz, who smashed a career-best 145 in the previous match, saw one catch land in no man's land but soon top-edged Taskin Ahmed to depart for six.
Shoriful compounded Afghanistan's woes by trapping Nabi leg-before to leave the tourists teetering at 15-4 inside nine overs.
Hashmatullah Shahidi and Najibullah Zadran stemmed the rot, but Shakib sent back the latter for 10 to stop their partnership from developing.
Shahidi dragged one off Taijul Islam onto his stumps to end his patient knock of 22 from 54 balls.
Omarzai helped Afghanistan past the 100-run mark after the quick departure of debutants Abdul Rahman (four) and Zia (five).
He was the last man dismissed, holing out a catch to Naim Sheikh at long-off off Taskin, who claimed 2-23.
Afghanistan are already only the second team to win an ODI series in Bangladesh in the past seven years, with world champions England being the other.
Victory in the match would have made them the first side to win all three matches of an ODI series in Bangladesh since Sri Lanka in 2014.
Following the ODI series are two T20s in Bangladesh's northeastern city of Sylhet on July 14 and 16.