Pope Francis on Thursday condemned any killing in God's name, but also insisted there were limits to freedom of speech and said other people's religion could not be insulted or mocked.
The pope made the comments in relation to attacks by Islamists on the offices of French satirical weekly Charlie Hebdo last week in which 12 people died.
"To kill in the name of God is an absurdity," the pope told reporters aboard a plane travelling from Sri Lanka to the Philippines.
But the 78-year-old pontiff also said "each religion has its dignity" and "there are limits".
"You cannot provoke, you cannot insult other people's faith, you cannot mock it," the pontiff said.
"Freedom of speech is a right and a duty that must be displayed without offending."
The Charlie Hebdo assault on January 7 was followed two days later by an attack on a kosher supermarket in Paris by a gunman claiming to have coordinated his actions with the two brothers who attacked the magazine.
In all, 17 people died over three days in the bloodiest attacks in France in half a century, which ended when commando units stormed two hostage sieges and killed all three gunmen.
The brothers, Said and Cherif Kouachi, attacked the Charlie Hebdo staff because they were outraged over the magazine's repeated depictions of the Prophet Mohammed.
Al-Qaeda then claimed it directed the men to carry out the killings, saying it was "vengeance" for the magazine's cartoons of the prophet.
The magazine this week published a "survivors" issue featuring an image of the prophet weeping, which sold out Wednesday before more copies of an eventual print run of five million hit newsstands.
The cartoon depicts the prophet holding a sign reading "Je suis Charlie" (I am Charlie), the slogan that has become a global rallying cry for those expressing sympathy for the victims and support for freedom of speech.
The cover of the new Charlie Hebdo has sparked fresh controversy and protests in some parts of the Muslim world, where many find the depiction of the prophet highly offensive.