The energy regulator's ability to claim hundreds of millions of pounds from the remnants of collapsed suppliers is facing a legal intervention brought by top insolvency professionals.
Sky News has learnt that three leading firms of administrators are seeking a court ruling to determine where Ofgem should rank as a creditor in the collapses of a trio of gas and electricity companies.
City sources said that a directions hearing due to take place in London on Thursday would be of "huge importance" in determining whether billpayers face yet higher costs at a time of already-soaring prices.
The three insolvency practitioners - Alvarez & Marsal, Grant Thornton and Teneo Restructuring - are understood to be seeking a determination on Ofgem's rights to claim outstanding Renewables Obligation Certificate payments from administrators.
More than two dozen suppliers have gone bust since last August, forcing millions of UK households to switch energy suppliers.
The largest, Bulb Energy, fell into a regime called special administration, meaning it was taken over by the government and funded by taxpayers until its assets can be sold.
All of the other collapsed suppliers - the largest of which was Avro Energy, with more than 500,000 customers - became insolvent, with their customer bases taken on under a mechanism known as the Supplier of Last Resort (SOLR).
Insiders said on Wednesday that this week's court hearing was also likely to determine whether the energy companies that had taken on customers through the SOLR system were entitled to file claims for customer balances.
Ofgem is understood to be a participant in the hearing, while British Gas, which is owned by Centrica, is also said to have been involved in the proceedings at an earlier stage.
The hearing is significant because it could set a precedent for how Ofgem is treated as a creditor in the insolvency proceedings of many of the more than 25 suppliers which have failed in the last six months.
Any direction issued by the court could therefore have an impact on whether Ofgem has the right to claim sums estimated to be worth hundreds of millions of pounds or whether those costs might have to be absorbed by the rest of the sector.
One source said the need for the legal hearing highlighted a major gap in Britain's energy sector regulation and said that those who devised it had failed to take into account the possibility of a large number of supplier failures.
On Wednesday, Ofgem said it would introduce two short-term measures in an attempt to help stabilise the UK retail energy market.
The regulator will force suppliers to offer existing customers the same tariffs as new ones, while suppliers will also have to pay peers a charge when they take on one of their customers, but only if wholesale energy prices fall sharply.
"Alongside tougher financial regulation, this will make sure that energy companies do not take disproportionate financial risks and suppliers who have done the right thing by purchasing energy in advance for their customers aren't penalised," an Ofgem spokesperson said.
The rise in gas and electricity charges, which will see the industry cap on average household prices soar by more than 50% to a maximum of £1,971 in April, has sparked urgent government intervention.
Earlier this month, Rishi Sunak, the chancellor, announced a £350-per-household support package to tackle the rising energy prices - a move that was criticised both as inadequate and poorly targeted.
Ofgem itself has been stung by criticism from a multitude of stakeholders about its handling of the crisis.
Jonathan Brearley, the watchdog's chief executive, told MPs this month that it should have been "more careful" about the financial resilience of new suppliers entering the market.
Some industry observers now expect the government to seek to reform or abolish Ofgem in its current form ahead of the next general election.
Centrica did not respond to several requests for comment about Thursday's court hearing, while the three sets of administrators all declined to comment.
Ofgem told Sky News: "We do not comment on ongoing legal proceedings".