After years fighting Iran-backed rebels in Yemen, Saudi Arabia is handing over billions of dollars to its war-torn neighbor to prevent economic collapse and an even deeper humanitarian crisis.

King Salman had ordered the transfer of $2 billion to the Yemeni central bank "to address the deteriorating economic situation," the Saudi government said on Wednesday.

The United Nations has estimated that 8.4 million people in Yemen are just "a step away" from famine. More than 10,000 people have been killed in the three years of war, and one million people are threatened by an outbreak of cholera.

"All of this money has been provided with the aim of boosting Yemen's financial and economic situation while bolstering the Yemeni riyal," the Saudi Ministry of Culture and Information said in a statement.

"As the value of the riyal goes up, the living conditions of Yemeni citizens will change for the better," it added.

Yemeni Prime Minister Ahmed bin Dagher pleaded on Tuesday for immediate help to prevent his country's currency from collapsing.

"Now, and not tomorrow, to save the Yemeni people from definite hunger," he tweeted.

Yemen has been torn apart by years of civil war between Iranian-backed Houthi rebels and forces loyal to the Yemeni government, backed by a Saudi-led regional coalition.

Yemen's president met Saudi Crown Prince Mohammed bin Salman in Riyadh on Tuesday.

Related: UN report accuses Iran and Saudis over Yemen

In an interview with CNN, bin Dagher said the riyal had lost half of its value. It was trading at 530 riyals to the U.S. dollar on the black market on Wednesday, down from 250 riyals in 2015.

The riyal has lost about 18% of its value already this month.

Speaking to CNN's Nic Robertson, bin Dagher claimed Houthi rebels were partly to blame for the plunging value of the riyal "as they tried forging and printing the currency against the law."

"The Iranians were involved in bringing currency printing equipment from Western institutions to print the Yemeni riyal and I believe they have succeeded. They flooded the market," bin Dagher added.

The plunging currency is driving up the cost of imports, including fuel. In the port city of Aden, market traders told CNN that higher prices were making it much harder to bring food from the farms, and to go out to sea to fish.

Saudi Arabia said it has transferred $3 billion to Yemen in total, including Wednesday's deposit.

-- Nic Robertson and Hakim Almasmari contributed to this report.