New York Community Bank is getting out of the mortgage business – sort of.

The bank announced Tuesday that it is selling its mortgage banking business, including its origination and servicing platforms, and the bank’s mortgage servicing rights portfolio, to Freedom Mortgage.

According to NYCB, its servicing portfolio carries an aggregate unpaid principal balance of approximately $21 billion, all of which will now go to Freedom Mortgage.

NYCB’s in-house mortgage business was part of the bank’s 2009 rescue of AmTrust Bank, which was facilitated by the Federal Deposit Insurance Corp.

And now the bank is selling those assets off.

A separate release from Freedom Mortgage provided a little more detail on the deal.

In its release, Freedom said that it agreed to buy approximately $500 million of “selected residential mortgage assets" from New York Community Bank's mortgage banking operation.

Freedom also highlights the MSR portfolio as a significant piece of the deal. According to Freedom, the servicing portfolio includes Fannie Mae- and Freddie Mac-approved mortgages as well as a “relatively small” amount of Ginnie Mae-insured mortgages.

In addition to selling its origination and servicing platforms and its MSR portfolio to Freedom, NYCB said that it is selling the “majority of our one-to-four family residential mortgage-related assets” to an affiliate of Cerberus Capital Management.

That sale is being conducted after the NYCB received approval from the FDIC to sell the assets covered under the bank’s loss share agreements that were part of the AmTrust acquisition.

But NYCB isn’t exiting the mortgage business entirely.

When asked by HousingWire whether the bank planned to continue in the mortgage business, a spokesperson for NYCB said that the bank will continue to provide mortgage banking products and services to its customers through a “third-party.” 

The spokesperson said that is the way that NYCB’s mortgage business operated prior to the AmTrust acquisition. “From our customers’ perspective, nothing will change,” the spokesperson said.

In a statement, Joseph Ficalora, NYCB’s president and chief executive officer, said that the deals are the right move for the bank right now.

“The decision to sell the mortgage banking business comes after many months of careful evaluation with our Board of Directors and our outside advisors,” Ficalora said. “Selling to a large, national, full-service mortgage banking company that would keep certain employees and maintain operations in the region were important considerations during the evaluation process.”

Under the terms of deal, Freedom is expected to retain “certain” employees from the NYCB’s Cleveland mortgage banking business. Freedom is also expected to maintain operations in the area.

“I am delighted to have the opportunity to add the quality assets, platform and select employees which are part of New York Community Bank to our Freedom family,” Freedom Mortgage CEO Stanley Middleman said. “I think there will be a great future for both firms as a result of this transaction.”

Ficalora said that the bank’s presence in Ohio is an “important component” of the bank’s business strategy, and after the sale, the bank will still have 28 branches, $2 billion in deposits, and more than 400 employees in the state of Ohio.

Full financial terms of the deals were not disclosed but NYCB said that the deals should result in a gain on sale of approximately $90 million on a pre-tax basis.

Ficalora said that agreeing to these deals are the next steps in the company’s strategic objectives.

“They allow us to focus on our core business model, including growth through acquisitions, generate liquidity which will be redeployed into higher-earning assets, enhance our returns through improved efficiencies, and reposition our balance sheet,” Ficalora added. “More importantly, they will enhance shareholder value through earnings and tangible book value accretion on an ongoing basis.”

The companies expect the deals to close in the third quarter.