The Rapid Action Battalion (RAB) on Monday detained Farabi Shafiur Rahman who had threatened several times to kill writer-blogger Avijit Roy through online postings.
Avijit Roy was hacked to death on February 26 evening on the campus of Dhaka University. His wife Rafida Ahmed Bonya, also a blogger, was severely injured in the attack.
The couple came under the attack when they went to visit the Ekushey Book fair at the Bangla Academy in the city.
Avijit was the founder of his blog Muktamona where he posted his thoughts that are alleged to have hurt the religious fundamentalists.
Farabi was the prime suspect in the sensational murder of Avijit, RAB officials told this correspondent.
He has confessed to have made threats to kill Avijit through online postings.
After more than four days of the murder of Avijit, a Bangladeshi born- US citizen, investigators are still in the dark about the assassins.
The blogger and his wife came to Dhaka from the US only a week before the grisly murder.
The Detective Branch (DB) of police has been officially assigned to investigate the sensational murder, second of its kind after the brutal killing, in similar style, of another blogger Rajib Haider in the city in 2013.
Both Avijit and Rajib were actively involved in the Ganajagaran Mancha, a youth platform that raised a strong demand for capital punishment to all war crimes suspects, at Shahbagh in the city.
Meanwhile, senior officials of the DB police told this correspondent on Monday that they were trying to track down the assassins of Avijit.
A group named Ansar Bangla-7 in a Twitter posting has already claimed responsibility for the murder. They termed it an achievement, Monirul Islam, Joint Commissioner of Dhaka Metropolitan Police, said on Monday. Hours after the hacking of Avijit, an unknown person called on the cell phone of Ajoy Roy, father of the victim, early Friday. The phone call came from Gaibandha area. The DB police were trying to track it.
Law enforcers could not confirm whether the Ansar Bangla-7 is new or any version of the terror outfit Ansarullah Bangla Team, which detectives found, linked to the murder of blogger Rajib Haider in 2013.
The RAB arrested Farabi after Dhaka had decided to take the help of the US Federal Bureau of Investigation (FBI) to investigate the murder of Avijit.
Avijit began one of his articles terming January's attack on Charlie Hebdo magazine in France "a tragic atrocity committed by soldiers of the so-called religion of peace."
Commander Mufti Mahmud Khan, Director at Legal and Media Wing of RAB, said during a press briefing at its Uttara headquarters in Dhaka that "Farabi confessed to his statements to kill Avijit, which he had made several times.
Mufti said a team of RAB-10 detained Farabi from Jatrabari bus stand area on Monday morning.
A dropout of the Physics Department at the Chittagong University, Farabi came to the limelight over making death threats to an Imam who had conducted the first namaz-e-janaza of blogger Rajib Haidar.
He was arrested at that time but managed to get out on bail from the High Court. The court said the police failed to produce proper evidence against Farabi.