Police in Bangladesh have arrested an Islamist militant over the killing of two gay rights campaigners, who died amid a surge in violent attacks against liberal activists and other minorities in the south Asian nation.

Xulhaz Mannan, 35, editor of Bangladesh's first magazine for gay, bisexual and transgender (LGBT) people, and fellow activist Mahbub Rabbi Tonoy, 25, were killed in a apartment in the capital Dhaka late last month, in an attack claimed by al Qaeda in the Indian subcontinent.

Shariful Islam, 37, a member of the banned group Ansarullah Bangla Team, was arrested in the southwestern district of Kushtia in connection with the murder, Monirul Islam, chief of the counterterrorism unit of Dhaka Police, told a news conference on Sunday.

The arrested man was brought to the news conference but did not comment.

The Muslim-majority nation of 160 million people has seen a series of attacks over the past year in which atheist bloggers, academics, religious minorities and foreign aid workers have been killed.

An elderly Buddhist monk was found hacked to death on Saturday at a temple in Bangladesh.

Police said three people had been arrested, although they said the motive was not yet clear.