Sri Lanka survived a middle-order collapse to beat Afghanistan ©Getty Images

Sri Lanka survived a middle-order collapse to beat Afghanistan by 34 runs in a rain-affected low-scoring thriller at the Cricket World Cup in Cardiff.

After they were put into bat by Afghanistan at Sophia Gardens, Sri Lanka looked well-positioned to register a formidable score when they reached 144-2.

But Sri Lanka proceeded to lose their next six wickets for just 36 runs as Afghanistan sensed an opportunity to skittle their opponents out for an attainable total.

Mohammad Nabi led the Afghan charge with the ball as he took four wickets, including three in a single over.

Sri Lanka were eventually bowled out for 201, as Kusal Perera top-scored with 78 runs in an encounter reduced to 41 overs per side because of rain in the Welsh capital.

His effort was the only considerable contribution to an fractured innings from the 1996 World Cup winners.

Chasing a revised target of 187 on the Duckworth-Lewis method, Afghanistan were all at sea and were staring a heavy defeat in the face when they slumped to 57-5.

Kusal Perera top-scored for Sri Lanka with 78 runs ©Getty Images
Kusal Perera top-scored for Sri Lanka with 78 runs ©Getty Images

Their hopes of recording a first World Cup win over a Test-playing nation were revived by Najibullah Zadran's defiant knock as he raised the prospect of a nervy finish.

Zadran was quickly running out of partners, however, and Afghanistan's slim hopes were all-but ended when he was run out for 43 with 42 runs still to get.

Lasith Malinga bowled Hamid Hassan with a trademark yorker four balls later to seal Sri Lanka's first win of the tournament.

"We had a good start but suddenly we lost a couple of wickets," said Sri Lanka captain Dimuth Karunaratne.

"That's the negative part but otherwise bowling and fielding was a high note.

"After losing the first game, it's not easy. 

"You have to keep your mind positive. 

"We have experience in these conditions."