Media playback is unsupported on your device Media caption A convoy of buses carrying police graduates was hit by two bombs

Taliban bombers have attacked an Afghan police convoy outside the capital Kabul, killing at least 30 people and wounding 50 others, officials say.

Two bombs hit a convoy of buses carrying graduates from a ceremony on the city's western outskirts.

Paghman District Governor Musa Khan told the BBC that all but two of the dead were police cadets.

The bombing was claimed by the Taliban and follows an attack on a bus just over a week ago that killed 14 people.

Image copyright EPA Image caption Most of the victims were police trainees who were on their way back from their initial training

A Taliban spokesman said that in Thursday's attack, the first bomber attacked one bus and when rescuers began to arrive the second drove an explosives-laden car into their vehicles.

The cadets were returning to Kabul from a training centre in Wardak province and were about to go on leave.

A softer target: Waheed Massoud, BBC News, Kabul

The Taliban's main targets are the Afghan government, international organisations and foreign military, but in particular the Afghan army and police force.

There have been numerous attacks on the Afghan police, even when the officers are unarmed. They are perhaps a softer target than the army, using un-armoured vehicles and lighter weapons.

The Taliban have tried to increase their attacks recently, especially after the appointment of their new leader.

Big attacks make headlines, but there have been many foiled attacks that are not widely publicised.

Taliban violence normally increases at this time of year, but this year there is an unusual upsurge in several provinces.

On top of that, the authorities have also for the first time engaged in several stand-offs with the Islamic State group in the east, which has forced hundreds of families to flee their homes.

Why are the Taliban resurgent in Afghanistan?

The attacks were immediately condemned by President Ashraf Ghani, who called the incident a "crime against humanity".

"While Muslims are busy praying during this holy month of Ramadan, the Taliban keep committing reprehensible crimes by killing innocent people and spreading fear and terror," he said in a statement.

Recent Taliban attacks

19 June: At least 14 Nepali security guards killed in suicide attack on minibus in Kabul

5 June: Afghan lawmaker and at least three other people killed by a bomb in Kabul.

25 May: 25 people killed in Kabul, including employees in judiciary

19 April: At least 64 people killed in explosion in Kabul

11 April: At least 12 police recruits killed on bus near Jalalabad

27 Feb: Suicide bomber kills 15 people near the Afghan defence ministry in Kabul

28 Jan: Afghan police officer drugs and kills 10 colleagues



Image caption The Taliban have been gaining ground all around the country

BBC diplomatic correspondent Jonathan Marcus says the latest violence in Afghanistan - just a few days ahead of a Nato summit in the Polish capital Warsaw - underscores the need for a continued Western engagement in Afghanistan where local security forces are having only limited success in restoring order.

The US and Nato combat mission in Afghanistan ended in December 2014.

US forces have taken on an advisory role since then, while also carrying out counterterrorism missions against so-called Islamic State and remnants of al-Qaeda.