A secular blogger has been hacked to death on the streets of Bangladesh for the second time in little over a month.

Washiqur Rahman was cut down with machetes in a frenzied attack by a group of men believed to be religious students this morning.

He was walking down a busy road in the centre of the capital Dhaka when he was assaulted, police said.

“Police on duty near the spot caught two attackers red-handed with three machetes as they were fleeing the scene after the incident,” police official Humayan Kabir told Reuters.

Students and teachers have protested in Dhaka after Avijit Roy was hacked to death last month (AFP/Getty Images)

Mr Rahman, believed to be around 26 years old, was taken to Dhaka Medical College Hospital but pronounced dead.

“His face has been distorted as the miscreants hacked him mainly on the face,” Salauddin, the head of Tejgaon Industrial Police, told the Dhaka Tribune.

The two arrested men were named by BDnews24 as “Zikrullah”, a madrassa student from Chittagong, and Ariful Islam, 20, a student at another Islamic college in Mirpur. A third suspect fled.

“I stabbed him because he humiliated my prophet,” said 20-year-old Zikrullah, who claimed he travelled to Dhaka and stayed overnight at a mosque to carry out the planned attack.

Bangladesh police officials parade suspects after blogger Washiqur Rahman was hacked to death in Dhaka (AFP/Getty Images)

Police believe Mr Rahman, who was reported to have blogged under the pen name of “Kucchit Hasher Channa” (Ugly Duckling), was targeted for his secular blog posts, which had drawn death threats and insults from online extremists in Muslim-majority Bangladesh.

According to the Dhaka Tribune, he had criticised “irrational” beliefs. He was described by Imran Sarker, head of a network of activists and bloggers in Bangladesh, as a “progressive free thinker”.

Mr Rahman, who relatives said worked at a travel agency, is the fifth secular blogger attacked in Bangladesh in recent years.

He was admirer of another anti-extremism blogger, Avijit Roy, who was murdered in a chillingly similar attack on 26 February.

On the day of his death, Mr Rahman’s Facebook profile still carried a tribute to Mr Roy with the hashtag #IamAvijit as his profile picture and slogan “words cannot be killed”.

Washiqur Rahman's Facebook page paid tribute to Avijit Roy, another secular blogger murdered in a similar attack last month

His page contained notes opposing Muslim extremism and violence and showed he was a member of secular groups including Atheist Bangladesh and one comparing “religious terrorism” against free speech in the country to the Charlie Hebdo massacre.

Mr Roy and his wife, who survived, were returning from a book fair at Dhaka University when they were attacked by two men with machetes.

Hundreds of students and activists gathered in days of protests to mourn Mr Roy's death and oppose the intimidation and murder of secular writers.

The US-based writer founded a popular Bengali-language blog, Mukto-mona, or Free Mind, which featured articles on scientific reasoning and religion.

An Islamic fundamentalist police said had threatened Mr Roy on numerous occasions over Twitter and Facebook has been arrested.

A previously unknown militant group, Ansar Bangla 7, claimed responsibility for the attack and the FBI is helping with the investigation.

Today's attack was the latest in a long line of extremists' attempts to silence secular and non-Muslim writers in Bangladesh.

In 2013, Ahmed Rajib Haider was hacked to death by machete-wielding militants associated with the Jamaat-e-Islami party in Dhaka.

A month before, prominent atheist blogger Asif Mohiuddin survived a similar attack and in 2004, Humayun Azad, a secular writer and professor at Dhaka University, was fatally wounded by militants while returning home from a book fair in the city.

Bangladeshi social activists shout slogans during a protest against the killing Avijit Roy in Dhaka on February 27, 2015. (AFP/Getty Images)

As well as the threat of violence, the government of Bangladesh has been criticised for arresting writers for “blasphemous” posts and shutting down or censoring atheist blogs in a crackdown that has sparked global protests.

The attacks come amidst a period of political turmoil in the country, with the government and main opposition group locked in a standoff that has created a sense of deepening insecurity.

Reporters Without Borders rates Bangladesh 146th among 180 countries its current global press freedom index.