With the wicket of Mohammad Amir (9), Herath completed 100 wickets against Pakistan and when 25 runs were needed for a win, Sri Lanka claimed the final wicket of Yasir (6 not out) but only to find it was a no ball.
He grafted for 34 runs from 69 deliveries and his dismissal left Pakistan needing 38 runs with three wickets in hand.
Sri Lanka started the day on 69 for four and were unable to bat past lunch as they capitulated to a combination of increased spin and reverse swing to be 138 all out.
Apart from Yasr, pacer Mohammad Abbas picked two wickets while Asda Shafiq, Haris Sohail and Hasan Ali chipped in with a wicket.
"Player of the Match, Rangana Herath said:" I have no idea (why he takes wickets against Pakistan). He has taken 95 wickets against them and needs five more to go past Kapil Dev to become the highest wicket-taker against Pakistan in Tests.
Saving lives is only goal, San Juan mayor says
Associated Press writer Danica Coto reported this story in San Juan and AP writer Laurie Kellman reported from Washington. Cruz called Duke's statement "irresponsible" and invited her to visit Puerto Rico to witness the devastation first-hand.
Ali then added 79 for the third wicket with Asad Shafiq who made 39 to take the fight to the visitors.
It was also a first defeat for Pakistan in Abu Dhabi in 10 Tests. He plays with positive intent and the hosts would hope for him to make a significant contribution.
Pakistan, led by Shah, bowled well in the morning. Rangana Herath bagged another five-for for Sri Lanka.
The 136 set to Pakistan was Sri Lanka's lowest defended target, improving on the 168 they set the Pakistanis in the Galle Test in 2009.
Defending a paltry target of 136, Sri Lanka--who got thrashed at home by India--came out with a brilliant bowling performance and bowled out Pakistan for 114, thus winning the match by 21 runs in the final session of Day five and taking a 1-0 lead in the series.
The second meeting starts on Friday in Dubai. Dickwella was unbelievable in the second innings, he got us to the 140 mark. "We wanted a good partnership up front but we didn't get that and that put us under pressure". Our batsmen played well but they didn't play any long innings. I've played almost 20 Tests, maybe that's why. "But obviously on the last day he was always going to be a factor and you have got to give him more respect but I would probably have liked to see our batsmen take him on". I was so happy with the remarkable achievement (400 wickets). All credit should go to the people behind me, from my parents to the team and the supporting staff.