Australia's two remaining oil refineries will be given up to $2.3 billion in taxpayer cash to stay open and contain the cost of fuel.
The public money will be shared between Ampol in Brisbane and Viva Energy in Geelong, dished out based on how much petrol and diesel each refinery produces and what profit margin they make on the fuel.
The package also includes $302 million to help both companies upgrade their facilities.
Prime Minister Scott Morrison described the payments as a matter of economic and national security.
He expects the package to preserve 1250 jobs and save drivers one cent per litre on petrol.
"This is a key plank of our plan to secure Australia's recovery from the pandemic and to prepare against any future crises," Mr Morrison said on Monday.
"Shoring up our fuel security means protecting 1250 jobs, giving certainty to key industries, and bolstering our national security."
Ampol chief executive Matt Halliday said the deal would ensure his company's refinery stayed open for some years.
"It will enable us to continue investing with confidence and supporting the jobs here at Lytton over that period," Mr Halliday told reporters.
Australian Workers Union national secretary Daniel Walton said the funding would safeguard critical assets.
"We've been saying for months Australia should never become a nation that can't make its own fuel and that we need not reach that dire situation if we get a few policy settings right," he said.
"We couldn't afford to become a nation without the capacity to produce crucial fuels, hoping shipping lanes remain open."
Australia's refining capacity has been sliding backwards for more than a decade, accelerated by the coronavirus pandemic, which slashed demand for jet fuel and drove down global oil prices and profit margins.
As a consequence, BP closed down its refinery at Kwinana in Western Australia and ExxonMobil shut its plant at Altona in Victoria.
If the two remaining refineries were to close, Australia would be forced to import all its fuel.
Energy Minister Angus Taylor said Australia's economy was reliant on fuel.
"Fuel is what keeps us and the economy moving. That is why we are backing our refineries," Mr Taylor said.
The deal includes a minimum stock holding obligation.
The latest funding injection builds on $211 million contained in last year's federal budget.
The package includes:
* Fuel security service payments worth up to $2.05 billion over nine years
* $50.7 million to help the refineries prepare for and meet their obligations under the fuel security framework
* $302 million for major infrastructure upgrades.