European finance ministers have reached a deal on rules for supervising eurozone banks ahead of an EU summit.
Two hundred of the biggest banks will come under the direct oversight of the European Central Bank, which will act as chief supervisor of eurozone banks.
The agreement - a key step towards banking union - will be put before European leaders later on Thursday.
New rules on prudent banking are seen as vital to bolster the euro, as bank failures triggered the financial crash.
'Brick by brick'
The measures are also aimed at preventing banking failures ending up on the books of eurozone governments.
"We have reached the main points to establish a European banking supervisor that should take on its work in 2014," said German Finance Minister Wolfgang Schaeuble, after 14 hours of talks ended shortly before dawn on Thursday.
"Piece by piece, brick by brick, the banking union will be built on this first fundamental step today," said EU Commissioner Michel Barnier.
Under the deal, banks with more than 30bn euros ($39bn) in assets will be placed under the oversight of the European Central Bank.
The ECB would also be able to intervene with smaller lenders and borrowers at the first sign of trouble, the BBC's Europe Editor Gavin Hewitt says.
Europe's finance ministers have taken another major step towards closer integration, with a significant transfer of authority from national governments to the ECB, he says.
The EU had already agreed that the ECB would act as chief supervisor of eurozone banks.
But the deal gives the ECB powers to close down eurozone banks that do not follow rules. It also paves the way for the EU's main rescue fund to come to the direct aid of struggling banks.
EU leaders believe that the first stage of a banking union - a Single Supervisory Mechanism (SSM) - can be put into place without having to change EU treaties.
But there had been some legal doubts about the subsequent stages - a joint deposit guarantee scheme and a joint resolution mechanism for winding up broken banks.
The UK, which is not in the eurozone, will not be joining the banking union but has won some protection against being marginalised when key decisions are taken, our Europe editor says.
London is the EU's main financial centre, and handles by far the biggest share of euro foreign exchange transactions. So the UK government is anxious to safeguard the City's powerful role and prevent its business leaching to a more integrated eurozone.
The UK's House of Lords EU Committee said on Wednesday it was "not convinced that an effective banking union could be created within the existing constraints of the European treaties".
France and Germany appear to have found a compromise on the scope of the ECB's new supervisory powers. The sticking point has long been the threshold at which the ECB would intervene - Germany argues that many of its regional banks are too small to warrant ECB attention.
The summit's chairman, European Council President Herman Van Rompuy, will try to get a commitment to launch the SSM in January 2014 at the latest. His vision for far-reaching eurozone integration is set out in a report, which will be the focus of the discussions.
The report included input from the European Commission, ECB and Eurogroup - the finance ministers of the 17 eurozone nations.
While banking union is the immediate focus, the report also proposes "contractual" arrangements between eurozone governments and the Commission, to prevent governments delaying, or reneging on, important economic reforms.
The quid pro quo would be central financial support for specific reforms - "solidarity" money from a new eurozone budget, to which all eurozone members would contribute. Such a mechanism could in future help to ease the kind of chronic unemployment that is afflicting Greece and Spain.
Only two EU members - the UK and Denmark - have formal opt-outs from the euro. The others still outside the euro are committed to joining, and can sign up to the banking union in the meantime.
The leaders are likely to avoid any measures that could trigger treaty change before the European elections in mid-2014, because treaty change is nearly always a thorny issue for the EU. It took seven years for the EU to adopt the Lisbon Treaty.
Germany's Constitutional Court has already flexed its legal muscles over eurozone integration. There is strong opposition in Germany and other richer eurozone nations to any further taxpayer-funded bailouts of indebted banks and governments.
Chancellor Angela Merkel insists that the banking union cannot be rushed - and she does not want to jeopardise her chances in Germany's elections next autumn.