Thousands of Pakistani Islamists had clashed with police earlier this week in protest against the arrest of their leader ahead of rallies denouncing French cartoons depicting the Prophet Mohammad

France has advised French citizens to temporarily leave Pakistan and warned of serious threats to French interests in the country, two diplomatic sources said on Thursday, after violent clashes there this week.

Thousands of Pakistani Islamists had clashed with police earlier this week in protest against the arrest of their leader ahead of rallies denouncing French cartoons depicting the Prophet Mohammad.

For Muslims, depictions of the Prophet are blasphemous.

The diplomatic sources said that a message had been sent overnight to French citizens and companies following threats by hard line Islamist group Tehrik-i-Labaik Pakistan (TLP) to target French interests.

The sources said the embassy sent a message to French residents in Pakistan recommending that French nationals leave the country and French companies shut down activities temporarily "due to the serious threats to French interests in Pakistan".

Relations between Paris and Islamabad have worsened since the end of last year after President Emmanuel Macron paid tribute to a French history teacher who was beheaded by an 18-year-old man of Chechen origin for showing cartoons of the Prophet in a class on freedom of speech.

The images sparked anger and protests in the Muslim world, especially in Pakistan, and even saw a Pakistani minister forced to withdraw comments she made that Macron was treating Muslims like Nazis had treated Jews in World War Two.

Last year, TLP ended a similar protest against France only after the government signed a deal agreeing to endorse a boycott of French products and making a move in parliament to expel French ambassador. It had this week demanded the envoy be expelled.

Pakistan has said it would outlaw the group and the arrest of its leader this week sparked further protests against France.

"It's a serious situation and we know that in Pakistan things can escalate quickly," said one of the diplomatic sources.

Pakistan's embassy in Paris did not immediately respond for comment.