They include five Spanish banks - Diada, Espiga, Banca Civica, Unnim and Cajasur. The other two were Germany's Hypo Real Estate and Greece's ATEbank.
The seven banks would need a total of 3.5bn euros (£3bn) of new capital to meet the standards required, CEBS said.
"[The failed banks] will have to agree with their respective supervisors a plan over a given time period which will explain how this weakness will be resolved," CEBS chairman Giovanni Carosio said.
The stress tests were conducted on a bank-by-bank basis, in a move designed to reassure investors over the health of Europe's financial sectors.
The seven banks failed because in this scenario, it was deemed that their "tier one" capital ratios - the strictest measure of capital - would fall below 6%, the threshold set for the test.
The five Spanish banks that failed, out of 27 tested, were regional savings banks, which racked up heavy losses following the collapse of the Spanish property market.
Following publication of the stress test results, the central bank said in a statement: "The exercise confirms that the Spanish banking system is sound, and in turn substantiates the savings bank restructuring and recapitalisation process pursued over the past twelve months by the Bank of Spain."
"The German banking system has shown itself to be robust and proved its resilience even under very pessimistic assumptions," financial watchdog Bafin and central bank, the Bundesbank, said in a statement.
It added that the only German bank that failed, Hypo Real Estate, "is currently undergoing a far-reaching restructuring process".
ATEbank was the only one of the six Greek banks that participated in the tests to fail.
Greek Finance Minister George Papaconstantinou said the results were positive and showed that "the Greek banking system can cope even in the extreme conditions of a stress test".
Add new comment