Iran's President Ebrahim Raisi on Saturday called for decisively confronting protesters with unrest over the death of a 22-year-old woman in police custody increasingly turning violent.

Speaking to the family of a member of the paramilitary Basij force killed in ongoing protests in the northeastern city of Mashhad, Raisi demanded decisive action against those "who disrupt the country's peace and security.”

He said the protests and disturbance of law and order should be differentiated, describing the angry demonstrations in the wake of Mahsa Amini's death in police custody last week as "riots".

Amini was taken to a police station in Tehran by members of the morality police last Friday over an alleged violation of the Islamic dress code, where she fainted and was later pronounced dead at a hospital.

Her family has rejected the police version of the incident as well as the CCTV footage that showed her collapsing inside the police station, claiming she was beaten after her detention.

Protests over her death, which first began in her native Kurdistan province, subsequently spread to several other provinces, including Tehran, with pitched street battles seen between protesters and riot police.

At least 35 have been killed in the protests, according to Iran's state media, including civilians and policemen.

Raisi, who returned from New York on Friday where he attended the 77th session of the UN General Assembly, also attended a ceremony in Tehran on Saturday marking the beginning of the school year.

In his speech, he said his government will not allow "enemies to endanger the security of the country and people", without elaborating.

On Friday, after protests turned violent in many parts of the country with reports of government buildings, ambulances, and banks being attacked, the general staff of Iran's armed forces issued a stern warning that “hostile, anti-revolution groups and their domestic agents” will be "dealt seriously”.

In a separate statement, the army spokesman condemned what he termed "destruction of public property and disruption of security", calling it an "evil strategy of the enemy" to weaken the country.

Iran's intelligence ministry also warned that those joining protests against the death of Amini will face prosecution.

"Considering the exploitation of recent incidents by counter-revolutionary movements, any presence, and participation in such illegal gatherings will result in judicial prosecution," a ministry statement said.

Amid growing unrest, mobile internet in Tehran and several other cities has been heavily disrupted, with a countrywide loss of connectivity recorded on leading cellular operators.

While Telegram, Facebook, and Twitter remain blocked in the country for years, accessible only through VPNs, Instagram and Whatsapp were restricted on Saturday amid growing protests across the country.

NetBlocks said on Thursday that Iran was experiencing its "most severe" internet clampdown since the deadly protests in November 2019 over fuel price hikes, when near-total outages spanned almost a week.