CatalunyaBanc on Tuesday posted a 12-billion-euro loss last year while northern-Spain based NCG Banco reported losses of 8 billion euros.

This adds to a record 19.2-billion-euro loss at Bankia reported in February and a 2.5-billion-euro loss at smaller lender Banco Mare Nostrum.

The losses were widely expected and largely covered by 41 billion euros of aid from Spain's European partners that was funnelled into the ailing banking sector last year.

But they also reflect the challenge that lies ahead for the government in turning around the lenders before selling them.

The Spanish government is now mulling operating the four banks under a single holding company. It has until 2017 to sell them under conditions agreed as part of the European rescue.

The move to create a common umbrella for the banks emerged by surprise last month after the government was forced to cancel a planned auction of CatalunyaBanc because bids came in well below expectations.

The 2012 loss there came courtesy of provisions for bad loans and other issues worth 1.4 billion euros and a 10-billion-euro hit from transferring toxic property assets into Spain's bad bank.

The bank in December received a cash injection of 9 billion euros in European funds, following earlier state aid worth around 6 billion euros.

The situation was similar at NCG Banco, which booked provisions worth 8.2 billion euros on its real estate assets.

The lender received a cash injection of 5.4 billion euros in European funds, following earlier state aid measures worth around 4.6 billion euros.

Since then, it has transferred some of its toxic property assets into the state's bad bank and taken off its balance sheet smaller lender Banco Gallego, which another state institution, the bank restructuring fund, sold this month to bigger bank Sabadell.

Those actions helped NCG Banco boost its net interest income, a key measure for banks representing the difference between earnings on loans and payouts on deposits, by 7.2 percent to 724 million euros.

Net interest income also increased by 10.6 percent at CatalunyaBanc, contrasting with the situation at other Spanish lenders which saw their net interest income fall in their recession-hit home market.

(Reporting by Julien Toyer; Editing by Fiona Ortiz and Patrick Graham)