A demonstrator waves Turkish and Islamic flags during a protest against Cumhuriyet, a staunchly secular opposition newspaper, in Istanbul on Jan. 15, 2015. Reuters/Murad Sezer

A Turkish court ordered Facebook on Sunday to ban pages that share content deemed insulting to the Prophet Muhammad, local media reports said Monday. The court also threatened to impose a total ban on the social networking site if it did not comply with the order, Reuters reported.

The order was reportedly given out on the request of prosecutor Harun Ceylan, who was investigating several social media sites, a local media report said, adding that the Presidency of Telecommunication and Communication, the nation's telecom authority, and the Access Provider Association, have also been notified about the court’s decision.

The move is the latest effort by President Tayyip Erdogan’s government -- believed to be following an Islamist-leaning agenda -- to crack down on material considered offensive to the religion, according to Reuters.

Earlier this month, a court ordered blocking websites showing the latest cover of Charlie Hebdo featuring a caricature of Prophet Muhammad condemning the attack on the French satirical magazine's headquarters in Paris on Jan. 7 that claimed the lives of 12 people.