“X has been and will continue to object to removal orders including government requests in courts to protect users when those requests do not align with principles of free expression, due process, or other local laws,” the company said on its Global Government Affairs account.
The statement said X maintains that "keeping the platform accessible in (Turkey) is vital to supporting freedom of expression and access to information.”
Imamoglu, seen as the main opposition challenger to Erdogan's 22-year rule, was arrested on March 19 and jailed on corruption charges. He was nominated as his Republican People's Party, or CHP's presidential candidate while in custody.
His arrest has been widely viewed as politically motivated although the government insists Turkey’s judiciary is independent and free of political influence. It triggered widespread demonstrations calling for his release and an end to Turkey’s democratic backsliding under Erdogan.
According to Engelli Web, a website that that tracks and reports internet censorship in Turkey, X restricted Imamoglu’s account in Turkey complying with a legal request by Turkish authorities who cited national security and public order concerns.
A notice that appears on Imamoglu's account, which has 9.7 million followers, says it has been "withheld in TR in response to a legal demand.” The account remains accessible outside of Turkey.
Gonenc Gurkaynak, a lawyer representing X in Turkey, said he had filed an appeal on behalf of the platform against the decision blocking the account. He said he had submitted a 27-page petition and hundreds of pages of supporting documents to the court.
The Turkish presidency's Center for Countering Disinformation said the court decision followed an investigation into a post by Imamoglu on X, which prosecutors assessed to be an incitement to commit a crime.
Authorities also ruled that because Imamoglu is currently detained, his account is not directly managed by him and therefore poses a threat to public order.
On Thursday, CHP's leader Ozgur Ozel welcomed X's decision to challenge the court order but said the platform should have resisted complying with it.
“X should not impose this restriction, which contradicts universal freedoms and the company’s own principles,” he said and urged Imamoglu's supporters to follow the mayor's international account and re-share his posts.
Ozel also criticized Erdogan's administration saying that “there probably is no other government that uses its judicial power so unfairly against its opponent.”
Despite his detention, Imamoglu had remained active on social media.
Supporters criticized the restriction as an assault on free speech in Turkey. They showed solidarity with the mayor by replacing their profile pictures with Imamoglu's image.