Image caption Last week Npower and British Gas announced that they would increase UK gas and electricity prices

Energy firms will be legally obliged to offer customers their lowest tariff, Prime Minister David Cameron has said.

He said legislation would be brought before Parliament, which would be "welcome" news for households facing rising gas and electricity costs.

Downing Street said options included making companies automatically place customers on the cheapest rates.

Ministers have previously encouraged consumers to shop around and make sure they are on the best available deals.

But consumer groups have complained that this is making little difference amid rising costs.

Last week Npower and British Gas both announced that they were increasing gas and electricity prices in the UK, blaming the government's policies as well as wholesale prices.

'Overhaul'

At Prime Minister's Questions, Labour MP Chris Williamson asked: "At your energy summit last year you promised faithfully that you would take action that would help people reduce their energy bills.

"Can you tell the House and the country how that is going?"

Mr Cameron replied: "We have encouraged people to switch which is one of the best ways to get your energy bills down.

"I can announce, which I am sure you will welcome, that we will be legislating so that energy companies have to give the lowest tariff to their customers, something that Labour didn't do in 13 years, even though the leader of the Labour party could have done because he had the job."

Measures are expected to be included in the Energy Bill, which will be published in the next few weeks.

Downing Street indicated the government was looking at a number of options, including forcing companies to write to customers once a year and place them on the cheapest tariff.

The prime minister's spokesman said although customers had been encouraged to move accounts in order to obtain the cheapest tariff, few did so, adding: "The energy market is not working for the benefit of consumers".

The spokesman said it was often the most vulnerable in society who ended up paying the highest bills.

Mr Cameron's announcement came before he and Chancellor George Osborne, a fellow Conservative, were due to meet Deputy Prime Minister Nick Clegg and Chief Secretary to the Treasury Danny Alexander, who are Liberal Democrats, to discuss energy policy.

Mr Osborne wants a new wave of gas-fired power stations and reductions in subsidies to renewable energy sources.

Liberal Democrats are happy to see more gas power in the short term but insist that the UK should continue to support renewables, such as wind power, to ensure that people are insulated against possible future rises in gas prices.

They argue that the UK should not waver from its legally binding climate change targets.

The chancellor says his approach would help to keep bills down.

The talks come just over a week after energy regulator Ofgem warned that the UK could face blackouts within a few years, unless steps were taken to secure future energy supply.

Shadow energy secretary Caroline Flint called for "a complete overhaul of our energy market".