(Bloomberg) -- In a deal that bypasses US sanctions and gives a lifeline to its power grid, Iraq agreed to swap oil for gas from Iran.

The deal, announced Tuesday on television by Iraqi Prime Minister Mohammed Shia Al-Sudani. ends Iraq’s long problem with Iran over payments for gas imports. Iraq has been struggling to pay gas dues since Iran came under US sanctions. 

Read More: Iraq, US Talks Lead to ‘Substantial’ Iran Gas Dues Arrangements

Iraq’s power generation declined sharply over the past few days as Iran cut 50% of gas shipments over the dues, Al-Sudani said. Despite being OPEC’s second-biggest producer of oil, Iraq has issues meeting its own power needs as it depends on other countries for energy imports. The US has been pressuring Iraq to end its reliance on Iran and develop own gas industry.

Iraq said it deposited the required $12.1 billion (€11 billion) in gas dues at the Trade Bank of Iraq, but the bank declined the transfers because of sanctions. 

©2023 Bloomberg L.P.