Iran warned the world on Monday to prepare for the possible withdrawal of the United States from the landmark nuclear deal agreed in 2015.

Trump has been railing against the Iran deal since before he was elected in November last year, calling it "one of the worst" in US history, and warned America could leave it "at any time".

In October, Trump unveiled an aggressive new strategy towards Iran when he announced he would not re-certify the landmark 2015 nuclear accord.

"The international community must be prepared for the US possibly pulling out of the JCPOA," said Iranian Deputy Foreign Minister Abbas Araghchi, using the technical name for the nuclear deal.

The next deadline for Trump to waive sanctions falls on Friday.

"It's been more than a year that the US president has sought to destroy the JCPOA with all his efforts," said Aragchi, speaking at the Tehran Security Conference.

"We in Iran are prepared for any scenario. The international community and our region will be the biggest loser, since a successful experience in the international arena will be lost," he added.

"Our region will not become a safer region without the JCPOA."

Iran signed the accord in 2015 with six world powers, agreeing to curb its nuclear programme in exchange for the lifting of many international sanctions.

A withdrawal by the US will lead to an "appropriate and heavy response", added foreign ministry spokesman Bahram Ghasemi.

Iranian Foreign Minister Mohammad Javad Zarif is due to travel for talks with the European parties to the deal - the UK, France, Germany and the EU - at the end of the week.

Zarif denied reports that the talks would focus on the recent protests in Iran that claimed 21 lives, saying such claims were "baseless and unfounded".

"Given the importance of JCPOA these days, and in particular considering the US destructive policies, based on talks we've had, we agreed to have a consultative meeting between Iran and the three European Union members," said Zarif, according to state broadcaster IRIB.