WASHINGTON—Amid the panic of the hour, with governments creating, borrowing and spending money like drunken sailors, German Chancellor Angela Merkel has emerged as the conscience of the developed world. Perhaps because she was raised in communist East Germany, or maybe because the memory of the 1920s and the evil political consequences thereof is so ingrained in the psyche of her fellow Germans, she is standing like a rock in the tempest, urging people to be prudent.

Of all the leaders participating in this week’s G-20 meeting in London, she is the only one who has reminded us of the origins of the current troubles and why the remedy favored by most governments is dangerous. “It happened,” she recently told the Financial Times, “because we were living beyond our means. . . . After the Asian crisis and after 9/11, governments encouraged risk taking in order to boost growth” by dumping ever-cheaper money into the financial system.

In response to the pressure to boost public spending, the German chancellor offers this devastating logic: “This crisis did not come about because we issued too little money but because we created economic growth with too much money, and it was not sustainable growth.”

One would think that Merkel is speaking from the comfort of a country that is being spared much of the punishment that others are receiving. Actually, as the world’s No. 1 exporter, Germany’s economy is on course to contract by 4.5 percent this year. No economy will be more affected than Germany’s, in absolute terms, by the 9 percent drop in international trade forecast by the International Monetary Fund.

Under pressure from the Social Democrats who are part of her Grand Coalition, Merkel has already had to spend much—about 4.5 percent of the country’s GDP over two years—in order to sustain demand. But she is saying enough is enough. Her opposition was crucial, for instance, in preventing the European Union from adopting a rescue package of $229 billion for Eastern Europe. She has steadfastly resisted the proposal to loosen the tight fiscal rules that govern the common currency, the euro. And she has withstood pressure from the Social Democrats to rescue Opel, the German subsidiary of General Motors, suggesting that bankruptcy might be in order.

Her skepticism is warranted not only by her country’s history but also by that of other nations. Japan spent more than $2 trillion trying to lift itself out of recession after the bursting of its real estate bubble in the 1990s. But real estate prices and indeed the economy did not pick up until the following decade. By then, government debt amounted to two years’ worth of Japan’s economic production.

It is not uncommon, in moments of financial and economic panic, for governments to lose their nerve. They are, after all, subject to the ire of their people. Nobody likes to face the kind of mob scenes we saw during France’s recent strikes, with livid workers accusing President Nicolas Sarkozy of “doing nothing.” And we are talking about a government that has been so interventionist and “protective” of its people that it recently conditioned aid to France’s automakers on a commitment to establish plants at home, rather than in countries such as the Czech Republic.

In this kind of environment, Merkel’s stance is especially courageous. It is particularly noteworthy that she is taking this position just months away from Germany’s general election, in which she will attempt to renew her tenure. Good luck.

American leaders have derided European socialism for years. But, following a trend started by George W. Bush, President Obama is now set to push federal spending to 28.5 percent of GDP, the highest level ever if we exempt World War II. In a little twist of history, it has now fallen on Germany, Europe’s leading nation, to warn America against the siren song of socialist-level spending.

Promisingly, Merkel’s message seems to have been heard at the grass roots on both sides of the Atlantic. Figures released in Britain this week show that, much like in the United States, the savings rate tripled in the last quarter. Despite monetary and fiscal efforts to the contrary, people are relearning to live within their means.

Albert Einstein is said to have described insanity as doing the same thing over and over again and expecting different results. The German chancellor is the one Western leader bearing this piece of wisdom in mind these days.