Two 'criminals' beheaded in Saudi Arabia were arrested when they were just 16 and 17 - including one teen set to start a new life in the U.S. at Western Michigan University.

Mujtaba al-Sweikat, then 17, was severely beaten all over his body, including on the soles of his feet, before 'confessing' to crimes including attending protests.

In 2017, staff at the university said the English language and pre-finance studies student showed 'great promise' and called for him to be released.

Abdulkarim al-Hawaj, 21, was also beheaded in public four years after being arrested in the country's Shia-majority Eastern province for spreading information about protests on WhatsApp.

Under international law, putting to death anyone who was under 18 at the time of the crime is strictly prohibited.

Abdulkarim al-Hawaj (left) was beheaded in Saudi Arabia after being arrested at age 16 for spreading details about peaceful protests on WhatsApp. Mujtaba al-Sweikat (right) was also executed. He was set to attend Western Michigan University

At the time of his arrest, staff at Western Michigan University said the English language and pre-finance studies student showed 'great promise' and called for him to be released

Human rights charity Reprieve said al-Hawaj was beaten, tortured with electricity and chained with his hands above his head until he 'confessed' to his crimes.

He had been at the King Fahd International Airport waiting to catch a flight with his family when he was arrested.

Reprieve said both men were sentenced to death at the end of sham trials when they were denied access to lawyers.

It claimed they were held for months in solitary confinement and their convictions were solely based on theirs 'confessions' which were extracted under torture.

At his trial, al-Hawaj was convicted on cyber crime charges including spreading information on WhatsApp 'as proscribed by the cyber crime bill' and sentenced to death.

It later emerged that the College of Policing in Britain had trained Saudi police in intelligence gathering on protesters despite fears it could be used to identify people who would be 'tortured or subjected to other human rights abuses'.

Reprieve Deputy Director Harriet McCulloch said: 'Many things can be used to justify a death sentence in Mohammed Bin Salman's Saudi Arabia, including "disobedience against the King", "preparing banners with anti-state slogans" and "incitement via social media".

'Mujtaba al-Sweikat and Abdulkarim al-Hawaj were teenagers sharing information about peaceful protests on their mobile phones.

'Saudi Arabia's western allies must act now, to prevent any more young people being killed for exercising their right to freedom of expression.'

Ali al-Nimr has been sentenced to 'death by Crucifixion' for taking part in a demonstration, inviting others to it and explaining how to give first aid to protesters. He is currently on death row

Abdullah al-Zaher (left) and Dawood al-Marhoon (right) were also sentenced to death for crimes they allegedly committed under the age of 18. Under international law, this is strictly prohibited

A third man among the 37 executed, Munir al-Adam, was just 23 when arrested at a government checkpoint in April 2012.

He was beaten on the soles of his feet and had to crawl on his hands and knees for days.

As a five-year-old boy he had lost his hearing in one ear following an accident, but after torture he lost hearing in the other and was left totally deaf.

He told a judge he had signed a confession because he was exhausted by the torture.

Those executed were members of the Shia community in Saudi Arabia's Eastern Province, where demonstrations have taken place since the Arab Spring swept through the region in 2012.

Three other prisoners who were under 18 at the time of their alleged crimes, Ali al-Nimr, Dawood al-Marhoon and Abdullah al-Zaher, remain on death row.

Al-Marhoon told Reprieve he was tortured and made to sign a blank document, to which Saudi officials then added his 'confession'.

Prisoner al-Nimr has been sentenced to 'death by Crucifixion' for taking part in a demonstration, inviting others to it and explaining how to give first aid to protesters.

Again, Reprieve claimed both al-Nimr and al-Marhoon were not given access to their lawyers and tortured for a confession.

The sentences were carried out in Riyadh, the Muslim holy cities of Mecca and Medina, central Qassim province and Eastern Province.

Saudi authorities said that one person was crucified after his execution, a punishment reserved for particularly serious crimes.

The men were executed 'for adopting terrorist and extremist thinking and for forming terrorist cells to corrupt and destabilise security', a statement published by the official Saudi Press Agency (SPA) said.

Saudi Arabia's interior ministry announced on Tuesday that 37 Saudi nationals had been executed [file photo]

Executions in the ultra-conservative kingdom are usually carried out by beheading.

It comes just days after security services in Saudi Arabia foiled an ISIS attack on state security unit in Riyadh.

Authorities in the country arrested 13 ISIS fighters in connection with the attack on a state security building north of the capital.

The arrests came after Islamic State claimed responsibility for Sunday's attempted attack on a state security building in Zulfi, a small city about 250 km (155 miles) northwest of the capital.

Security forces have also confirmed that they had killed four alleged Islamic State militants who had planned Sunday's attack, according to SPA.

According to reports, the attempted terrorist attack was being planned for the Interior Ministry building in the al-Zulfi suburb in Riyadh.

Following the arrests, the terrorists were identified as Saudi militants who belonged to the terrorist organisation ISIS.

On Sunday, police forces raided a nearby rest-house they said the militants had rented for use as a bomb factory, and seized suicide vests, homemade bombs, Kalashnikov rifles and Islamic State publications.

Also among the items seized were five explosive belts, organic fertiliser and two laptops.

Th executions were carried out just days after terrorists targeted a building in Riyadh in a foiled plot [file photo]

After crushing an al-Qaeda insurgency over a decade ago, deadly bombings and shootings have been carried out by Islamic State against security forces and minority Shi'ite Muslims in Saudi Arabia, the world's top oil exporter.

Islamic State and al Qaeda have for years criticised the leadership of the Western-allied kingdom, accusing it of deviating from their strict interpretation of Islam and advancing the interests of their U.S. enemies.

The arrests comes as the terrorist group begins to lose their last stronghold in Syria after taking it over in 2014.

In March, the US-backed Syrian Democratic Forces announced a victory over the ISIS 'caliphate' but claimed the fight had not yet ended.

At least 100 people have been executed in Saudi Arabia since the beginning of the year, according to a count based on official data released by SPA.

Last year, the oil-rich Gulf state carried out the death sentences of 149 people, according to Amnesty International, which said only Iran was known to have executed more people.

Rights experts have repeatedly raised concerns about the fairness of trials in Saudi Arabia, governed under a strict form of Islamic law.

People convicted of terrorism, homicide, rape, armed robbery and drug trafficking face the death penalty, which the government says is a deterrent for further crime.