Two women take smartphone pictures in front of Hagia Sophia in Istanbul.
Istanbul - Social media giants have to ensure they have local representatives in Turkey and to comply with court orders over the removal of certain content or face heavy fines
Turkey's parliament on Wednesday passed a controversial bill giving the government greater control of social media and criticised by human rights advocates as an attempt to increase online censorship.
Under the new law, social media giants such as Facebook and Twitter have to ensure they have local representatives in Turkey and to comply with court orders over the removal of certain content or face heavy fines.
The legislation targets social networks with more than a million unique visits every day and says servers with Turkish users' data must be stored locally.
If companies refuse to comply, they will face fines and restriction of bandwidth making the platform unusable.
The bill was submitted by the ruling AKP and its nationalist partner the MHP, which have a majority in the parliament, and passed after debates beginning on Tuesday and lasting into Wednesday.
After the night-long debate, the parliament went into summer recess till October.
Human rights groups and the opposition are worried over what they call the erosion of freedom of expression in Turkey, with thousands of people subject to criminal proceedings for "insulting" President Recep Tayyip Erdogan on social media.
They argue that increased control of social media will also limit Turkish access to independent or critical information in a country where the news media is in the hands of government-friendly businessmen or controlled by the state.
"Why now?" asked Yaman Akdeniz, professor at Istanbul's Bilgi University and also a cyber rights expert.
"While print and broadcast media platforms are already under government control, social media networks are relatively free. Social media has become one of the few spaces for free and effective expression in Turkey," he told AFP.
Human Rights Watch expressed concerns that the law would enable the government to control social media, to get content removed at will and to arbitrarily target individual users.
"Social media is a lifeline for many people who use it to access news, so this law signals a new dark era of online censorship," said Tom Porteous, deputy program director at Human Rights Watch in a statement before the legislation passed.
The legislation has aroused deep concerns for many Internet users in Turkey who mobilised online in recent weeks using the hashtag "don't touch my social media".
Ibrahim Kalin, Erdogan's spokesman, brushed off fears the law would hamper free speech.
"There is no obstacle to social media users freely expressing their opinion," he told CNN-Turk television on Tuesday.
"Here is the rule: whatever is a crime in real world is also a crime in cyber world ... there must be a limit to criticism."
Erdogan vowed to tighten government control over social media earlier this month after he said "dark-hearted" users insulted Finance Minister Berat Albayrak and his wife Esra, the president's daughter, following the birth of their fourth child.
And last month, the Turkish leader met with a spate of negative comments during a video-conference with young people.
The Turkish presidency then turned off comments but there were 388,000 clicks on the "thumbs down" button, compared with 114,000 on the "thumbs up" button.
Erdogan is not a fan of social media despite a large following on different platforms, including Twitter.
He once compared the media platforms to a "murderer's knife" and previously promised to "eradicate" Twitter.
His government previously blocked Twitter and YouTube in 2014 after audio recordings were posted implicating the president, then prime minister, and his inner circle in an alleged corruption scandal.
Erdogan's aversion of social media also dates back to anti-government protests in 2013, which were often mobilised by Twitter and Facebook posts.
A Turkish court in January lifted a ban on the online encyclopaedia Wikipedia after almost three years.
According to Twitter's latest "transparency report" for the first half of 2019, Turkey ranked number one for seeking content removal with more than 6,000 requests.