MEMBERSHIP of the euro is meant to be for keeps. Europe's currency union is supposed to be immune from the sort of speculative attack that cracked the exchange-rate mechanism, the system of currency pegs that preceded it, in 1992-93. A lesson from that time is that when the foreign-exchange markets are far keener on one currency than another, even the stoutest official defence of a peg between the two can be broken. Inside the euro zone, no one can be forced to devalue because no one has a currency to mark down.

The strains in euro-zone bond markets this year show that there are other ways for markets to drive a wedge between the strong and the weak. Concerted selling of their government bonds has forced Greece and now Ireland to seek emergency loans from other European Union countries and the IMF. Portugal may soon join them in intensive care. Spain is in the markets' sights and the trouble is spreading to Italy, home of the world's third-largest market for public debt.

The convergence of government-bond yields that was spurred by the euro's launch has thus been sharply reversed. The idea that the euro itself might also be reversible and that one or more countries might revert to national currencies is no longer unthinkable. This would be costly and cause huge financial shocks for both leavers and those left behind. But the bar to exit, though high, would be surmountable.

The idea of breaking up the currency zone raises at least three questions. First, why would a country choose to leave? Second, how would a country manage the switch to a new currency? Third—and perhaps most important—would leavers be better off outside the euro than inside it?

The main reason why a country might choose to leave the euro is to regain the monetary independence it sacrificed on joining and to set monetary policy to suit its own economic conditions. This could apply to the strong as well as the weak. Germans may long to have the Bundesbank in charge again. It would surely not take risks with long-term inflation, by keeping liquidity lines open to weak foreign banks, or with its political independence, by buying government bonds. And given the strength of the German economy, it might raise interest rates soon.

As it is, the European Central Bank (ECB), though based in Germany and modelled on the pre-euro Bundesbank, has had to react to the economic and financial weaknesses of the rest of the euro zone in ways that Germans do not like. Add to this taxpayers' disgust at having to stand behind the public debts of less thrifty countries, and the idea of abandoning the euro looks enticing to some Germans. That appeal might extend to countries, such as Austria and Netherlands, with strong economic ties to Germany. They might prefer to join a new D-mark block than to stay with the euro, were Germany to leave.

Weak economies might also hanker for a monetary policy tailored to their own needs. The euro may have abolished market-based nominal exchange rates but it has led to marked divergences in real exchange rates (see chart). Consumer prices in peripheral countries have risen at a faster rate than in Germany since the start of the euro in 1999. So have wages, making it hard for firms in those countries to compete with Germany in foreign markets and with low-cost imports from Asia in their home markets. Leaving the euro would allow Italy, Spain and the rest to devalue and bring their wage costs into line with workers' productivity.

How could this be done? Introducing a new currency would be difficult but not impossible. A government could simply pass a law saying that the wages of public workers, welfare cheques and government debts would henceforth be paid in a new currency, converted at an official fixed rate. Such legislation would also require all other financial dealings—private-sector pay, mortgages, stock prices, bank loans and so on—to be switched to the new currency.

The changeover would have to be swift and complete to limit financial chaos. Bank deposits would have to be converted at the same time, and the same rate, as overdrafts and mortgages to keep the value of banks' debts in line with their assets. When Argentina broke its peg with the dollar in 2001, it decreed that bank deposits should be switched at a more favourable exchange rate than loans, in an effort to appease savers. This imposed losses on an already crippled banking system, and led to a sharp contraction in domestic credit.

The central bank would have to distribute new notes and coins fast. It would also have to set interest rates, and would need a lodestar, probably an inflation target, to guide it. Whatever the official exchange rate at a changeover, the new currency would quickly find a market level against the euro and other currencies. A new D-mark would be expected to rise against the now-abandoned euro; a new drachma or punt would trade at a big discount to its official changeover rate—a devaluation, in effect.

The switch to the euro was smooth, but it was planned for years in great detail and in co-operation among countries. The reverse operation would be far messier. The mere prospect of euro break-up could cause bank runs in weak economies as depositors scrambled to move savings abroad to avoid forced conversion. If Germany were the leaver, it would face an inward flood.

To prevent such a drain, a weak country thinking of leaving the euro would have to impose caps on bank withdrawals, other forms of capital controls, and perhaps even restrictions on foreign travel. That might not work in a region as integrated as Europe—and if it did it would depress the economy by limiting the circulation of cash for commerce. It would also cut the country off from foreign credit, because foreign firms and banks would fear that their money would be trapped. Trade would suffer badly, at least for a while.

A departing country would also have to prepare for legal challenges. A change in the currency in both weak and strong countries would impose devastating losses on businesses and depositors at home and abroad. Savers who could not get their money out of banks before its forced conversion would not be happy to be paid in a devalued currency. Many would sue, as happened in Argentina. The legal uncertainty would further hamper the banks, which would be loth to extend credit for fear they might yet be forced to make depositors whole.

Foreign banks and pension funds holding weak economies' euro-denominated government bonds would suffer an effective default. They might sue, too. A sovereign might expect to win its legal battles if it drafted its conversion laws well and if it could assert the primacy of its law over European law. But the European dimension would at the very least mean that costly legal battles would drag on.

All the while a government seeking to replace the euro with a devalued currency could scarcely rely on bond sales to finance its operations. But such a country would have long been cut off from capital markets anyway. The prospect of monetary independence would give it new options. In the run-up to passing a conversion law, the government could pay some of its bills, including wages, by issuing small-denomination IOUs, which could be traded for goods and services. These would form a proto-currency that would trade at a discount to the remaining euros in circulation—a shadow price of the devaluation to come. Since the money supply would be shrinking fast, as euro deposits fled the country, this sort of paper would be accepted readily. Scrip issued by the province of Buenos Aires circulated freely months before Argentina's dollar peg broke.

Germany would be in a happier position. Should it opt to leave, it would have an incentive not to convert its stock of euro-denominated debts to claims in a new, stronger currency. It could instead choose to repay those depreciating debts over time. Rather than invite legal disputes, however, it might instead go for a comprehensive conversion and keep balance-sheets straight. Germany would in any case be able to issue cheap debt in the run-up to conversion. A rush out of euros into German assets in anticipation of revaluation would drive up the prices of Bunds—conceivably to a point where the interest rates on them were negative.

Even so, Germany would face costs it could not control. A new D-mark would surely rise steeply, harming the country's exporters. Exit from the euro area would deplete its customers in the rest of the zone of the cash and credit needed to buy German goods. As a big creditor, it holds lots of assets elsewhere in the zone. The value of these would plummet in new D-marks, and a contraction in credit in the rump of the euro zone would mean that the value of assets, including businesses that might otherwise have survived, would be destroyed. Germany would no longer be able to influence the euro area's monetary policy. It could not prevent the ECB from stoking inflation, which would undermine the real value of German loans made to euro-zone banks, businesses and governments.

A determined country could leave the euro and establish its own currency again: nothing is truly irreversible for a sovereign nation. But even the most wilful and powerful state could not fully control the banking chaos and social unrest that a forced currency conversion would unleash. It would be a curious decision for Germany to seek to abandon the euro in search of greater monetary and fiscal stability. It would first have to endure a long period of financial disarray.

Is it worth it?

Countries at the euro zone's periphery that face years of austerity and high unemployment inside the euro may find it harder to believe that things could be much worse if they left. A devaluation would spare them the grinding wage deflation needed to price the unemployed back into work (though it would not address the economic weaknesses that lie behind poor competitiveness). The spectre of bank runs, high funding costs, default and social unrest might not seem so scary in today's conditions: some countries are already vulnerable to these. Efforts to ameliorate these problems have so far proved inadequate (see article).

Therein lies the danger for the euro. The cost of breaking up the single currency would be enormous. In the ensuing chaos and recrimination, the survival of the EU and its single market would be in jeopardy. But by believing that a break-up cannot happen, the euro zone's authorities will always tend to stop short of the radical measures needed to hold the project together. Given the likely and devastating chaos, it would be a mistake for a country to choose to leave. But mistakes occur in times of stress. That is why some are beginning to contemplate the unthinkable.