A security team is seen at the area where the bodies of two Scandinavian women tourists were found dead, near Imlil in the High Atlas mountains, Morocco. On December 21, The bodies of the two women were flown back to Scandinavia. File picture: 2M via AP

Rabat - The bodies of two women from Denmark and Norway murdered by suspected jihadists while hiking in the High Atlas mountains in Morocco were flown back to Scandinavia on Friday.

The remains of Danish student Louisa Vesterager Jespersen, 24, and 28-year-old Norwegian Maren Ueland were put on a plane that left Casablanca for the Danish capital, a police spokesman said.

Moroccan authorities said Thursday that four suspects arrested following the murder of the two tourists had pledged allegiance to the Islamic State (IS) group.

The bodies of the two women were found Monday after they had pitched their tent at an isolated mountain site two hours' walk from the tourist village of Imlil.

One of them was beheaded, according to a source close to the investigation.

Imlil is a starting point for trekking and climbing tours of Mount Toubkal, which at 4,167 metres is the highest summit in North Africa.

Hours after the grisly discovery authorities announced the arrest of a first suspect and later said he belonged to an "extremist" group, while the three other suspects were arrested on Thursday.

Moroccan investigators are probing a link to Islamic extremism after a video emerged showing the suspects "pledging allegiance" to the Islamic State group, the Rabat prosecutor has said.

Authorities were working to determine the authenticity of a video posted on social media networks allegedly showing the murder of one of the tourists, according to the prosecutor.

"At this point, there is no tangible evidence that the video is not authentic," Norway's criminal investigations agency Kripos said Friday.

- 'In shock' -

All four suspects were arrested in Marrakesh, an hour away from the scene of the murder.

Younes Ouaziad, 27, lived with his parents in the working-class Al-Azzouzia neighbourhood.

His family and neighbours said Friday they were "in shock". 

"He was a boy without any history, private. There was nothing to suggest he could do something like that," 35-year-old Abdelaati, a vegetable seller in the neighbourhood, told AFP.

The murders have prompted condemnation from authorities in Denmark and Norway.

Danish Prime Minister Lars Lokke Rasmussen denounced what he called a "beastly crime".

Norway's Prime Minister Erna Solberg condemned what she called a "brutal and meaningless attack on innocents".

Moroccan government spokesman Mustapha Khalfi described the killings as a "terrorist act" while Prime Minister Saad Eddine El Othmani said it was a "stab in the back of Morocco and Moroccans".

Tourism is a cornerstone of Morocco's economy, accounting for 10 percent of national income.

Morocco has been spared jihadist attacks since 2011, when a bomb attack on a cafe in Marrakesh's famed Jamaa El Fna Square killed 17 people, most of them European tourists. 

AFP