WASHINGTON—The midterm elections in Argentina have dealt a devastating blow to President Cristina Kirchner and her husband, former President Nestor Kirchner, who is the power behind the throne. The couple’s support has not only been seriously eroded among the larger society but also, and perhaps more importantly in a country in which “Peronismo” represents an entire culture, within their own party.

The government lost its majority in Congress, and was defeated in all the major electoral districts, including Buenos Aires, Santa Fe, Mendoza and Cordoba, as well as the Kirchners’ home province of Santa Cruz. The former president, who was running for Congress, was beaten by a political neophyte—businessman Francisco de Narvaez.

The electoral result was a few years in the making. The Kirchners, who came to power in 2003, enjoyed strong popularity for a while. But then their authoritarian and demagogic style, and their populist economic model based on milking the agricultural cow at a time when soybeans were in high international demand and then redistributing money to their vast political constituency, began to generate fatigue. The decision to raise taxes on farmers created a split with the rural base. Subsequent moves—the nationalization of the pension funds, the takeover of private companies such as Aerolineas Argentinas—widened the scope of resentment against the Kirchners. Suddenly, even decisions that had been popular years before, such as replacing the International Monetary Fund with Venezuela’s Hugo Chavez as a source of loans to the Argentine government, were frowned upon.

The big question is: What now? As Argentine analyst and author Joaquin Morales Sola told me, the electorate is signaling a clear shift toward market-friendly policies and against the nationalist/populist model the Kirchners came to symbolize—a model that had really started at the end of 2001, when a financial crisis led to a succession of short-term governments bent on undoing market reforms enacted in the 1990s. This shift can be assumed from the fact that most of the leaders who came out victorious in the elections—Buenos Aires Mayor Mauricio Macri, Vice President Julio Cobos, former Gov. Carlos Reutemann in the province of Santa Fe, and de Narvaez—are either former allies of Kirchner who at one point denounced his ideological stance, or longtime critics who have decried his closeness to Chavez.

However, given the absence of a clear political definition on the part of these leaders and the inconsistency that the opposition has shown so far, it is by no means a foregone conclusion that Argentina will be able to begin the real cleansing process of rolling back Peronismo and pushing strongly for globalization, a market economy and the return to a real separation of powers.

As is so often repeated, Argentina was once one of the 10 wealthiest countries in the world—a nation to which millions of Europeans flocked in the late 19th and early 20th centuries because of its stable institutions and open economy. Sometime in the 1930s, it all began to unravel. In the 1940s, Juan Domingo Peron took over and accomplished something that few nations have ever managed: “undevelop” a country—as author Mariano Grondona aptly put it—that was already developed, at least by the standards of that time. Although the “Peronistas” have been in and out of power since, and contradictory ideological factions within the party have at various times taken over the leadership, Argentina has never really ceased to be the populist nation that Peron molded.

The challenge for those who achieved a tremendous victory against what until recently looked like the all-powerful Kirchner couple is not just to undo the latest version of Peronismo—it is to undo more than half a century of populism. That, of course, will be an impossible task without support from some of the “Peronistas” themselves, who have a grip on the system. Many of them are Kirchner critics but still consider themselves heirs of Peron.

In the 1990s, a center-right Peronista, President Carlos Menem, attempted to reverse Peronismo with free-market reforms while still claiming Peron’s mantle. Tragically, those reforms did not go far enough and were tainted by corruption, too much public spending and a rigid monetary system that collapsed in 2001. It is time to try again and to get it right once and for all.