The comment was met with a barrage of angry replies from users of the social network.

"Israel must respect international law but obviously has the right to defend itself. It is a huge tragedy that the violence escalates," Löfven wrote.

Most of the comments were critical of the political party leader's stance, with some accusing him of betraying the legacy of the late Olof Palme and Anna Lindh, who were critical of Israel when they were in office.

The Swedish foreign ministry has long since advised against travel to Gaza due to the precarious security situation and the fact that the Swedish authorities have limited capacity to assist citizens in the area.

The foreign ministry advises all Swedish citizens seeking to flee the area that the UN is offering assistance in coordinating with Israel and Egypt to secure exit permits. Citizens are encouraged to contact the Swedish embassy in Tel Aviv and the consulate in Jerusalem, preferably by email.

Story continues below…

According to media reports several thousand people fled from northern Gaza on Sunday fearing an Israeli ground invasion and after Israeli warnings that it was targeting the area in its push to end rocket attacks from Gaza militant groups.

The BBC reported that some 17,000 people had sought refuge in its camps, and that according to Gaza officials some 172 Palestinians have been killed.

The current conflict began last Monday following a period of tension after the killing of three Israeli teenagers and one Palestinian teenager in Jerusalem.