By David Luhnow and José de Córdoba

During a recent visit to a coal-fired power plant run by Mexico's state electricity utility, President Andrés Manuel López Obrador recalled with nostalgia that only a few decades ago, the state produced all of the country's electricity. Now, he lamented, it generated only half, thanks to free-market policies over the past three decades that had hurt ordinary Mexicans. "In that period they tried to destroy Pemex and the Federal Electricity Commission with reforms to take market share away from them to give it to private companies, especially foreign ones, " he said, referring to Mexico's former state oil and electricity monopolies.

The silver-haired populist is trying to reverse course. It is part of what critics see as a drive to recreate the Mexico of his youth in the 1960s and 1970s, when the country was a one-party state with an all-powerful president, a compliant congress and courts, and an economy powered by state-run firms, especially in energy. It was a time before the country embraced globalization in the mid-1980s and democracy in the late 1990s.

"It's the return of the Tlatoani," says political analyst Denise Dresser, referring to ancient Aztec kings that began a long tradition in Mexico of powerful rulers, including Spanish viceroys and Mexican presidents so dominant that a 1970s joke had the president asking what time it was only to be told "whatever time you say it is, Mr. President."

What is different about the 67-year-old Mr. López Obrador -- widely known by his initials, AMLO -- is how he has managed to dominate the political and economic life of this country of 126 million not by defying its democratic system but by exploiting it. Elected by a landslide in 2018, he is by far the most authentically popular politician this country has seen in a generation, boasting 60% approval ratings despite a weak economy and a pandemic that hit Mexico particularly hard.

Now, many in business and growing numbers of middle-class Mexicans fear that he will use that power to subvert the very democracy that elevated him. Even presidents from Mexico's former ruling Institutional Revolutionary Party (PRI) -- described by the Peruvian novelist Mario Vargas Llosa as the "perfect dictatorship" -- dutifully obeyed the Mexican constitution by retiring after a single six-year term. Mr. López Obrador, by contrast, is hollowing out a number of the institutions that limit presidential power, and many worry that he will try to stay in office beyond 2024, or at least hold sway over a handpicked successor.

A crucial test comes this Sunday, when Mexicans vote in midterm elections for the entire lower house and half of the country's governorships. At stake is whether the president's Morena party, which is expected to win, can gain a big enough majority to change the constitution and speed up his agenda for change. No matter the outcome, most analysts expect the president to step up his attempts to concentrate power.

Mr. López Obrador's party is already proposing to end the autonomy of independent agencies designed to check presidential power, ranging from antitrust regulators to a body responsible for public transparency. Mexico's congress funds these agencies and names their members, and the president believes they should be folded into the executive. In April, a ruling-party senator paraded a coffin emblazoned on the side with the name of the electoral agency's top official. Mr. López Obrador also said recently that he planned to replace the head of Mexico's independent central bank with someone possessing a greater sense of the "social" or "moral" economy.

"The next three years will be marked by increasing uncertainty. At risk are the election agency, the autonomous institutions, the judiciary, the central bank, the energy reform, public finances and the constitution itself," said Carlos Ramírez, head of the political risk firm Integralia.

Populist autocrats have become a familiar phenomenon in key emerging markets, including Brazil, India, Turkey, Russia and the Philippines, according to Larry Diamond, a professor at Stanford University who studies global political development. Such charismatic leaders cast themselves, he says, as saviors of a good and honest people laid low by a corrupt traditional establishment, represented by institutions ranging from the courts to the media. "Where does this lead? Cronyism, crony capitalism, massive corruption and almost invariably a gradual restriction of political rights and rule of law, subjugation of the judiciary, media, and the downward slope of an autocrat," Prof. Diamond says. "López Obrador has mastered the course."

Whatever their similarities, none of those other countries shares a 2,000-mile border with the U.S., which counts on Mexico as its second-largest trading partner. If Mr. López Obrador creates a political or economic crisis, the spillover effect could be profound, affecting everything from migration to trade to antidrug cooperation. "There are not enough people in the U.S., either in Washington or on Wall Street, that understand what López Obrador means for Mexico," says Duncan Wood, senior adviser to the Mexico Institute at the Woodrow Wilson Center in Washington, D.C.

As Mr. López Obrador approaches the midway point in his six-year term, the Mexican economy is faltering. Even before the pandemic, Mexico was in recession thanks to measures by the president that spooked business investment, such as canceling a partially built new airport for Mexico City and scrapping a nearly complete $1.4 billion brewery built by the U.S. maker of Corona beer over water-use concerns. Mexico hasn't had a single initial public stock offering in four years.

Mexico's economy contracted 8.5% during his first two years in office and lost at least 850,000 jobs, most of them during the pandemic. An estimated 400,000 businesses have also closed in the past year, according to government figures. For the past year, the biggest group of immigrants caught crossing the U.S. border illegally are Mexican adult males looking for work.

The president's economic vision for Mexico is clearest in the energy sector. In February, he pushed through a law forcing the national electric grid to buy power produced by the inefficient state utility first, even though it costs more and generates more pollution than power from private firms and renewable energy producers, which have been relegated to the end of the line despite having invested tens of billions of dollars in recent years. Economists say that the move will push up electricity prices, reduce reliability and make Mexico's trade-dependent economy less competitive.

Within weeks of the new law, Mr. López Obrador also ordered a halt to all new mining concessions, threatened to yank the operating license of a Canadian mining company, passed another law giving the government power to cancel the operating licenses of privately run filling stations and to hand them to the state oil giant, and floated the idea of nationalizing the country's lithium reserves. "We are going backwards," says José Antonio Crespo, a political analyst at the CIDE university in Mexico City. "We are losing what we gained in the last 30 years."

The uncertainty and the ensuing pandemic have dramatically slowed business investment. Gross fixed investment from both the government and business fell 4.6% during 2019, Mr. López Obrador's first full year in power, and then another 18.2% in 2020, according to figures from the national statistics institute. Foreign direct investment for the past two years has been down about $5 billion a year to $30 billion.

Mr. López Obrador's office did not respond to repeated requests for comment on the issues raised in this article. Historian Lorenzo Meyer, who counts himself as one of the president's supporters, said that fears of his authoritarianism are overblown: "There's not a single political leader who is in jail, the army hasn't acted against political opponents, the intelligence service has been dismantled, no newspaper has been shut down."

Finance Minister Arturo Herrera has said Mexico is set for strong growth in coming years, emerging from the pandemic with stable public finances and the new USMCA trade deal with the U.S. and Canada, completed in November 2019, just ahead of the pandemic. "In recent months, investors are starting to reconsider their supply chains and taking advantage of the trade deal," he said in a written response to questions.

Few expect Mexico to turn into another Venezuela, which has suffered an economic collapse under its Socialist regime. Unlike many Latin American populists who bankrupted their countries with spending sprees, the Mexican leader, the son of shopkeepers, is cautious with the public checkbook. He has eliminated thousands of government jobs and slashed salaries, directing some $26 billion in savings to public works and expanding cash handouts to the poor.

That fiscal restraint, and Mexico's deep ties to the U.S. economy, may prevent Mr. López Obrador from steering the economy into a major crisis. Mexico's courts, too, could prove more robust than those in Venezuela. Federal judges in Mexico have temporarily suspended dozens of the president's initiatives to expand state control of the economy, including the new electricity law, saying the actions might violate the constitution. The president vows to press ahead.

Economists predict a rebound for the country this year and next, driven by a strong U.S. economy lifting demand for Mexican exports, by far the strongest part of Mexico's economy but also the one that analysts say interests the president the least. Growth this year could hit 6%, according to estimates by investment bank J.P. Morgan. But after that, most economists expect sluggish growth unless the government changes course.

(MORE TO FOLLOW) Dow Jones Newswires

06-04-21 1115ET