At the time, then prime minister David Cameron denounced the plan and accused Mr Miliband of wanting to live in a "Marxist universe".

But in an article for The Sun, Mrs May said the energy market is not working and the Government needs to intervene.

"Like millions of working families, I am fed up with rip off energy prices," she wrote.

"Too many people simply aren't getting a fair deal. And it is the vulnerable, and those on low incomes, who are being hit hardest.

"So I am making this promise: if I am re-elected on June 8, I will take action to end this injustice by introducing a cap on unfair energy price rises."

Under the Tory plan, the cap would be set by the independent regulator for the energy market, Ofgem.

Justifying the move, the Conservatives pointed to a report last year by the Competition and Markets Authority (CMA) which found 70% of domestic customers of the "Big Six" energy companies were on SVTs.

The CMA calculated that cost to consumers of "excessive prices" charged by the Big Six to be about £1.4 billion a year.

On Monday British Gas owner Centrica hit out at the proposed cap, warning that it could lead to higher bills for consumers and reduce competition in the sector.

In a trading update, the group said it had put forward "alternative ways" to improve the market and address concerns as part of its regular dialogue with ministers.

"Centrica does not believe in any form of price regulation. Evidence from other countries would suggest this will lead to reduced competition and choice, and potentially higher average prices," it said.

"We have had a regular and constructive dialogue with the Government and have proposed alternative ways to improve the market further and address their concerns, without resorting to price regulation."

The group said trading in the first quarter of 2017 had been hit by warmer than usual weather, leading to lower than expected energy consumption.

During that period it lost 261,000 customers, and it has now put in place measures to slash a further £250 million in costs, with 1,500 jobs facing the axe this year.

Labour's shadow business secretary Rebecca Long-Bailey said the Conservatives had still not provided any proper detail as to how the cap would work.

"When the Tories say they'll 'cap' bills, the question they need to answer is whether they can guarantee bills won't go up for people next year - that's the real test," she said.

"A cap suggests a maximum amount that can be charged, not a promise that bills won't go up year on year."

For the Liberal Democrats, former energy secretary Sir Ed Davey said: "It is never a good idea to copy the economic strategy of Ed Miliband.

"As the Conservatives pointed out at the time, this will damage investment in energy when it is needed more than ever."

Josh Hardie, deputy director general of the CBI said: "Putting customers at the heart of the energy market is important for everyone.

"The Competition and Markets Authority's thorough two-year investigation identified low levels of consumers switching energy providers as a challenge, and put forward a range of recommendations to address this.

"It is important that these measures bed in before looking to further interventions.

"A major market intervention, such as a price cap, could lead to unintended consequences, for example dampening consumers' desire to find the best deal on the market and hitting investor confidence."