By Ruma Paul

DHAKA (Reuters) - Police in Bangladesh on Sunday shot dead an Islamist militant wanted for the killings of several liberal bloggers and gay rights activists, a senior official said.

The militant, identified as Sharif, one of the leaders of the banned group Ansar Ullah Bangla Team, took part in the killing of blogger Avijit Roy, U.S. citizen of Bangladeshi origin, in Dhaka last year, police official Abdul Baten said.

Sharif was also behind the killing of two gay rights activists in April, as well as four other bloggers and a publisher, the police officer told a news conference.

Bangladesh, a deeply religious but moderate Muslim-majority country of 160 million people, is struggling to control attacks by Islamist groups on bloggers critical of extremism, atheists and religious minorities.

This month the government, facing growing pressure from an international community alarmed by the spate of attacks, launched a crackdown across the country under which more than 11,000 people have been arrested.

A 19-year-old suspected Islamist militant was killed in a shootout on Saturday, days after he critically wounded a Hindu college teacher, police said.

Police officer Baten said Sharif was killed in a gunbattle that erupted following a raid on a militant hideout on the outskirts of Dhaka.

"During the pre-dawn raid, our personnel had to open fire after three suspected militants on a motorbike started firing at them," he said, adding that Sharif died in the gunfight while two others fled.

Rights groups and opposition parties say hundreds of innocent people have been taken into police custody as part of the crackdown.

(Editing by Sanjeev Miglani and Ros Russell)