Ally Bank continued its retreat from home lending by agreeing Tuesday to sell a portfolio of mortgage servicing rights to Ocwen Financial Corp. (OCN) for roughly $585 million.

For Ally, the $94.8 billion-asset unit of Ally Financial, the deal means a near-complete exit from the mortgage lending business. For Atlanta-based Ocwen, the acquisition is another successful bid in building its massive mortgage servicing platform.

The sale by Ally comprises mortgage servicing rights on loans with an unpaid principal balance of $85 billion as of Jan. 31, and includes the transfer of representation and warranty liability associated with the majority of loans sold, the company said in press release. The deal is expected to close in stages over the next few months and is subject to approval by Fannie Mae and Freddie Mac.

As part of the deal, Ally has the right to sell its remaining $30 billion portfolio of MSRs to Ocwen though it has received interest from other buyers, the company said. That portfolio includes borrowers who could refinance in the short-term, the company said.

"Ally continues to make significant progress in exiting its non-strategic mortgage activities," Barbara Yastine, Ally Bank's president and chief executive, said in a press release. She said the sale would allow Ally to focus on its "direct banking franchise and advancing customer-centric deposit activities, as well as continuing to grow its key role in Ally's auto finance operation."

Separately, Ally said it completed the sale of its correspondent and wholesale broker mortgage operation to Walter Investment Management Corp. for an undisclosed price.

In February, Ocwen completed a $2.1 billion purchase of servicing rights from Residential Capital, the former mortgage-lending arm of Ally Financial that filed for bankruptcy protection in May 2012. Ocwen and Walter, which are partners, successfully bid in October to buy ResCap's mortgage servicing and origination assets for $3 billion.

Ally, which is 74% owned by the U.S. government, has been working to limit its exposure to mortgages after a $17.2 billion bailout during the financial crisis. Following the sale of MSRs, Ally will continue to originate jumbo loans and conventional conforming residential mortgages for its $9.8 billion held for investment portfolio.

"The bank will continue to evaluate its strategy around mortgages and make adjustments as appropriate," Ally spokeswoman Gina Proia said Tuesday.

Subscribe Now

Access to authoritative analysis and perspective and our data-driven report series.

14-Day Free Trial

No credit card required. Complete access to articles, breaking news and industry data.