The United States government embarked on the biggest bail-out in its history yesterday when it confirmed the takeover of mortgage giants Fannie Mae and Freddie Mac in a bid to stem further economic fallout from the ongoing housing crisis.

The government will take on debts worth around £2800bn - nearly half the outstanding mortgages in the US - after warnings that the companies' collapse would spark further instability at home and abroad.

Treasury Secretary Henry Paulson said the actions were being taken because "Fannie Mae and Freddie Mac are so large and so interwoven in our financial system that a failure of either of them would cause great turmoil in our financial markets here at home and around the globe".

The huge potential liabilities facing each company, as a result of soaring mortgage defaults, could cost American taxpayers tens of billions of dollars, but Mr Paulson stressed that the financial impact if the two companies had been allowed to fail would be far more serious.

"A failure would affect the ability of Americans to get home loans, auto loans and other consumer credit and business finance," he said.

Both companies were placed into a government conservatorship that will be run by the Federal Housing Finance Agency, the new agency created by Congress this summer to regulate Fannie and Freddie.

The emergency nationalisation dwarfs that of Northern Rock in Britain, which has sparked ongoing debate over the wisdom of state intervention in the mortgage market.

Whitehall sources said yesterday that the Prime Minister and his Chancellor, Alistair Darling, were split on how far the government should underwrite lenders, with Gordon Brown more enthusiastic about taking radical action.

A report on the issue by Sir James Crosby, the former chief executive of HBoS, was "still on Alistair Darling's desk", Schools Secretary Ed Balls said yesterday.

The mortgages owned or underwritten by Fannie Mae and Freddie Mac are around 25 times as big as the Rock's obligations, and twice the size of the UK economy.

Executives of both institutions, which are shareholder-owned but mandated by the US Congress to provide funding to the housing market, have been ousted.

Herb Allison, a former vice- chairman of Merrill Lynch, replaces Daniel Mudd at Fannie Mae, and David Moffett, a former vice- chairman of US Bancorp, heads Freddie Mac in place of Richard Syron.

The Federal Reserve and other federal banking regulators said in a joint statement that "a limited number of smaller institutions" have significant holdings of common or preferred stock shares in Fannie and Freddie, and that regulators were "prepared to work with these institutions to develop capital-restoration plans".

The two companies had nearly £20.39bn in preferred shares outstanding as of June 30, according to filings with the Securities and Exchange Commission.

The Republican and Democrat candidates, John McCain and Barrack Obama, both issued statements in support of the government intervention.

Mr Paulson and James Lockhart, director of the Federal Housing Finance Agency, stressed that their actions were designed to strengthen the role of the two mortgage giants in supporting the US housing market.

Meanwhile, in the UK mortgage lender Nationwide says it is in advanced talks over mergers with the Derbyshire and Cheshire building societies.

The proposed tie-ups, which may trigger windfall payments for members of the two smaller societies, will consolidate Nationwide's position as the UK's biggest building society. The Derbyshire is the UK's ninth-biggest building society, with the Cheshire ranked at number 11.