Industrial production rose by more than expected in February, lifting hopes the UK will avoid another recession.
Industrial production rose by 1% in February compared with January, but was still down 2.2% from a year earlier, according to the Office for National Statistics (ONS).
Manufacturing output, which is one of the components of industrial production, rose 0.8% from January.
However, trade figures showed that the UK's trade deficit widened in February.
The overall production index was lifted by the biggest rise in the production of electricity and gas since October, helped by the prolonged spell of cold weather.
And all the sectors that are collated to make up the overall industrial production figure - including mining and quarrying, energy supply and waste management - saw an increase in February, the first time this has happened since July last year.
The increases followed a fall in output in January. Industrial output had dropped by 1.3% in January while manufacturing output fell by a revised 1.9%, the ONS said.
Even if the economy has avoided another recession, the big picture is that the economy is still struggling to recover or to rebalance towards production and exports
Samuel Tombs, Capital Economics
Despite the month-on-month improvement in February, industrial output is still only at the same level as September last year.
However, economists said that the improvement could be enough to avoid the UK slipping into a second successive quarter of declining growth.
Ross Walker from RBS said: "It's hardly a dramatic recovery but it does look to be avoiding a symbolic triple dip recession."
The UK's economy shrank by 0.3% in the last three months of 2012, with weak industrial production the main drag.
If the economy contracts during the first quarter of this year then it will be back in recession for the third time in five years.
The National Institute of Economic and Social Research (NIESR) said it now expected GDP to have grown 0.1% in the first three months of the year, which would imply that a recession has been avoided.
"Our estimates suggest that both production sector output and the broader economy were broadly flat in the first quarter of this year," NIESR said.
The first official estimate of gross domestic product for January to March is due on 25 April.
Separate figures from the ONS showed that the goods trade deficit in February widened to £9.4bn from January's £8.2bn, hit by a 4.7% fall in exports to non-EU countries, including a £329m drop in exports to the USA
The UK's deficit on trade in goods and services was £3.6bn in February, compared with a deficit of £2.5bn the month before.
"Even if the economy has avoided another recession, the big picture is that the economy is still struggling to recover or to rebalance towards production and exports," said Samuel Tombs, an economist at Capital Economics.
Lee Hopley, chief economist at the EEF manufacturers' organisation, said: "While many manufacturers are increasing efforts to grow in new markets, another round of weak trade data suggests challenging conditions persist across a number of key markets.
"In line with much of the survey data we've seen since the start of the year it looks like industry will struggle to make a positive contribution to overall growth in the first quarter of 2013."