Countrywide was almost bankrupted by the US housing crisis
US banking giant, Bank of America, is free to take over the country's biggest mortgage lender, Countrywide Financial, after the move got regulatory approval.
The US Federal Reserve said, after looking at the case for and against the $4bn (£2.04bn) purchase, that it could go ahead.
Analysts say the deal is a lifeline for distressed lender Countrywide.
The firm - a key participant in the sub-prime sector - had been hit by the severe downturn in the housing market.
In August 2007, Bank of America had invested $2bn in Countrywide.
Speaking after the Fed decision, Bank of America boss Ken Lewis said: "This transaction represents a rare opportunity for Bank of America to significantly gain market share in the mortgage business, allowing it to expand in a cornerstone financial product."
The Fed said that after the deal Bank of America would remain the largest depository institution in the US, controlling $773.4bn of deposits.
Sub-prime lenders such as Countrywide gave loans to those with poor credit records or unpredictable incomes.
During the housing boom, a huge number of people took out mortgages to take advantage of lower borrowing costs.
But with US interest rates climbing over the past two years, many borrowers have been unable to repay their monthly loans, prompting huge defaults and repossessions.