Despite several hitters getting off to strong starts, the Afghanistan bowling attack caused Sri Lanka a great deal of trouble on the Pune pitch, limiting the total to 241.
After losing Rahmanullah Gurbaz in the first over, Afghanistan recovered to reach their target with seven wickets and 28 balls remaining in the chase, which was a lesson in poise.
Ibrahim Zadran had set the tone early in the innings with a brilliant 39, and other players followed with half-centuries from Rahmat Shah (62), Hashmatullah Shahidi (58*), and Azmatullah Omarzai (73*).
Afghanistan emerged victorious in a tumultuous encounter as Sri Lanka had threatened to reveal a weaker middle order.
After Dilshan Madushanka sent important opener Gurbaz out for a duck in the opening over, Afghanistan bounced back magnificently through the powerplay to establish a solid foundation in pursuit of 242 to win.
The rest of the powerplay and beyond saw Ibrahim Zadran and Rahmat Shah put on a steady partnership to calm the nerves, but Sri Lanka responded when Madushanka came back to get Zadran for a smart 39, leaving Afghanistan 74/2 and the game hanging in the balance.
With Rahmat Shah scoring a superb half-century, a sizable third-wicket partnership turned the tide in favor of Afghanistan.
However, just when it appeared to be a pleasant pursuit. For a 74-ball 62, Kasun Rajitha removed the number three.
The game was going to come down to the wire, with Azmatullah Omarzai and Captain Hashmatullah Shahidi holding a virtual tie in the needed and scoring rates.
And they did so with style, each scoring outstanding half-centuries in a partnership that appeared to be getting stronger as it went on.
Afghanistan also strengthened their semi-final credentials by winning with a notable net run rate boost, thanks to a squandered opportunity that gave them the winning runs.