Iran and China signed a 25-year "strategic cooperation pact" Saturday in the latest expansion of Beijing's flagship trillion-dollar Belt and Road Initiative as the US rivals move closer together.
Negotiations for the deal, launched five years ago, sparked controversy in Iran last year and virtually no details of its contents have been released.
China is Iran's leading trade partner and was one of the biggest buyers of Iranian oil before then US president Donald Trump reimposed sweeping unilateral sanctions in 2018 after abandoning a multilateral nuclear agreement with Tehran.
The China-Iran pact, which Tehran said included "political, strategic and economic" components, was signed by the two countries' foreign ministers, Wang Yi and Mohammad Javad Zarif, an AFP correspondent reported.
"We believe this document can be very effective in deepening" Iran-China relations, Iran's foreign ministry spokesman Saeed Khatibzadeh said, recalling that the pact had first been proposed during a visit to Tehran by Chinese President Xi Jinping in January 2016.
Xi and his Iranian counterpart Hassan Rouhani agreed then to establish a roadmap for "reciprocal investments in the fields of transport, ports, energy, industry and services."
"Iran's government and people are striving as they always have to broaden relations with trustworthy, independent countries like China," supreme leader Ayatollah Ali Khamenei said at the time, describing the proposed cooperation agreement as "correct and reasonable".
Xi has championed the Belt and Road Initiative, a plan to fund infrastructure projects and increase China's sway overseas.
In July last year, controversy erupted over the proposed deal after former president Mahmoud Ahmadinejad charged that negotiations were being held for a "new, 25-year agreement with a foreign country" without the knowledge of the Iranian people.
The foreign minister was heckled in parliament when he assured lawmakers there was "nothing secret" in the proposed deal, which he promised would be publicly announced "once it has been finalised".
The government has yet to honour that promise and few details have been made public.
Wang's visit to Tehran comes just days after he hosted Russian Foreign Minister Sergei Lavrov for talks in the Chinese city of Guilin.
The three governments all face difficult relations with Washington after President Joe Biden's administration vowed to remain firm in its dealings with them, despite a renewed emphasis on diplomacy.
China and Russia are both parties to the troubled 2015 nuclear accord with Iran that Biden has said he hopes to revive.
They were both deeply critical of the unilateral sanctions on Iran reimposed by Trump and have backed efforts to revive the agreement.
Biden has said he is not seeking "confrontation" with China, but that there will be intense competition between the rival superpowers.
"I told him (Xi) in person on several occasions we're not looking for confrontation, though we know that there will be steep, steep competition," the US president said.
Everything has beauty, but not everyone can see.