Cyprus had been a blip on the radar screen of Europe’s long-running debt crisis — until now.

Hobbled by a devastating banking crisis linked to a slump in Greece’s economy, where Cypriot banks made piles of loans that are now virtually worthless, Cyprus on Saturday became the fifth country in the euro union to receive a financial lifeline since Europe’s debt crisis broke out. As the euro zone’s smallest economy, Cyprus had hardly been considered the risk for the euro union that Greece, Ireland, Portugal or Spain were.

But the surprise policy by the International Monetary Fund, the European Central Bank and the European Commission is the first to take money directly from ordinary savers. In the bailout of Greece, holders of Greek bonds were forced to take losses, but depositors’ funds were not touched.

Mr. Anastasiades, who was elected just a few weeks ago, called the decision “painful” but said it would lead to “the historic and definitive rescue of our economy.” He said the consequences of rejecting the deal would be the collapse of at least one of Cyprus’s major banks, amid widespread weakness in the country’s banking system.

Cypriot banks are loaded up on bad loans made to Greek companies and individuals, which have turned sour at an alarming rate as Greece deals with the fourth year of a devastating economic and financial crisis.

“I’m not surprised that people are trying to get their money out in Cyprus; that is entirely to be expected,” Mr. Kirkegaard said. “They wake up Saturday morning and are told on the radio their bank deposits are at risk.”

The deposit tax, which is expected to raise 5.8 billion euros, or $7.6 billion, appeared aimed at gleaning large amounts of cash from the accounts of wealthy Russians, who have poured deposits into Cypriot banks in the last several years. Chancellor Angela Merkel of Germany, who faces a pivotal election in September, has been particularly concerned that most of the bailout money could wind up in the hands of Russian gangsters and oligarchs, a fear backed by a recent report by Germany’s intelligence agency. Officials in Cyprus have said there is no proof the Russian cash is of questionable origin. They insist they cracked down on money laundering before joining the European Union.

Because Russian depositors would have to share the burden, it would ultimately relieve Cyprus from its debt load by allowing a one-time payment upfront rather than deeper cuts to salaries and pensions or additional privatizations in the future.