A court in the western city of Jhenidah condemned 21 militants in connection with serial bomb explosions on 17 August, the private ATN Bangla television network reported.


Eighteen of the defendants were in court when the sentence was read, while another two remain fugitives.


Lawyers said they planned to appeal the sentences.


In a separate case, a court in northeastern Sylhet city sentenced a man to death for hurling a homemade bomb outside the house of a judge, slightly injuring him, on 18 October.


The militants were sentenced for their part in a deadly wave of blasts that saw more than 400 bombs explode almost simultaneously across Bangladesh last year, officials said.


The bombings, claimed by an outlawed Islamic militant group, killed three people and rocked a nation which had previously denied having a serious problem with extremism.


Amirul Islam, administrative officer at the court said the accused were all members of the militant group Jamayetul Mujahideen Bangladesh (JMB).


The authorities have vowed to
end the violence

Babul Ansari, one of the condemned men, was employed as a security guard at the Bangladesh parliament at the time of the attacks, Motaleb Hossain, the court's prosecutor told AFP.


Hossain said the case was the first successful prosecution in connection with the attacks in which small explosive devices were detonated in almost every town and city in the country.


JMB leaflets were found at the blast sites calling for the imposition of strict Islamic law.


Suicide bombings


The group has also been blamed for a series of subsequent attacks including several suicide bombings, the first in Bangladesh, which have claimed the lives of 28 people including four suicide bombers.


The government has admitted it woke up late to the threat posed by religious extremists and vowed to root out those responsible.


Bangladesh, with a population of 140 million, is the world's third largest Muslim-majority country.