Germany said Monday it was reviewing a request by Turkey to prosecute a TV satirist who crudely insulted President Recep Tayyip Erdogan on air, amid a bitter row over free speech.
Chancellor Angela Merkel's spokesman Steffen Seibert told reporters that Berlin had received a "note verbale", a formal diplomatic protest, from Ankara asking for "criminal proceedings" against celebrity comedian Jan Boehmermann.
Seibert said officials at the chancellery, foreign ministry and justice ministry would decide after "careful review" in the coming days whether a probe under the rarely enforced section 103 of the criminal code -- insulting organs or representatives of foreign states -- could go forward.
If prosecutors decide to bring charges, they could carry a sentence of up to three years in prison.
German prosecutors last week opened a preliminary probe against Boehmermann, 35, over his so-called "Defamatory Poem", recited with a broad grin on public television, which accused Erdogan of having sex with goats and sheep.
That investigation was based on complaints from several German viewers. However the Turkish government's request gives the affair a far broader diplomatic dimension and puts Merkel in the line of fire.
Seibert stressed Berlin's constitutional commitment to freedom of expression, calling it "non-negotiable".
"This applies, and this is very important to me, regardless of whether the chancellor personally finds something artistically successful or repellent, tasteful or tasteless," he said.
Erdogan's spokesman Ibrahim Kalin confirmed the complaint to reporters in Ankara.
"This type of insult against a president, against an entire people, has nothing to do with freedom of expression and the press, it is a criminal offence," he said.
During the broadcast on March 31, Boehmermann gleefully admitted the piece flouted Germany's legal limits on free speech and was intended as a provocation.
In the German-language rhyme, Boehmermann, seated before the Turkish flag and a portrait of Erdogan, also charges that the Turkish leader loves to "repress minorities, kick Kurds and beat Christians while watching child porn".
Seibert quoted Merkel last week criticising the poem as "deliberately insulting" during a telephone call with Turkish Prime Minister Ahmet Davotoglu, in a move Berlin had hoped would smooth ruffled feathers.
The case comes at an extremely awkward time as Europe, and Germany in particular, are relying on Turkey to implement a pact to curb the influx of migrants setting sail for the EU from Turkey's shores.
German critics have savaged the government's muted response to Turkey's diplomatic protest, accusing Merkel of kowtowing to the Turkish leader.
News website Spiegel Online said the impression had arisen "that Merkel can be blackmailed over the EU-Turkey migrant pact" and said the government now faced a serious dilemma between democratic principles and the letter of an evidently outdated law.
The head of the Turkish community in Germany, Gokay Sofuoglu, blasted the poem as "not satirical but inappropriate and insulting" and demanded an apology from Boehmermann.
The comedian was reacting to Ankara's decision to summon Germany's ambassador in protest last month over a previous satirical song broadcast on German TV which lampooned Erdogan in far tamer language.
The two-minute clip "Erdowie, Erdowo, Erdogan", set to the tune of a 1980s pop song, takes aim at the Turkish president over his alleged spending excesses and his government's crackdown on civil liberties.
Free speech advocates have rallied around Boehmermann, with his employer, public broadcaster ZDF, saying his show would "continue as planned" although it has removed the offending clip from its website.
And the chief executive of one of Europe's top media companies, Axel Springer AG's Mathias Doepfner, gave Boehmermann his full support, accusing Berlin of hypocrisy for even considering allowing the comedian to be prosecuted.
"In Germany a kind of crisis of state broke out just because you called Mr Erdogan a 'goat fucker'," Doepfner wrote in an open letter to Boehmermann in the Welt am Sonntag newspaper.
He defended the poem as a "work of art" intended to "force people to consider how a society deals with satire and -- even more important -- satire intolerance among non-democrats".