COBIJA, Bolivia — When , ’s first indigenous president, took office a decade ago, he vowed to put this impoverished town in the Amazon Basin on the kind of pedestal often reserved for a capital city.

He filled its coffers with profits from the country’s natural gas industry. He even seized large estates and handed them to new arrivals like Tania Chao, 19, whose family received a house when it came to Cobija with nowhere to live.

Yet when Mr. Morales asked Ms. Chao to vote for him last week, in a referendum to let him run for a fourth term, she did not feel that she could return the favor. The president had improved the town, she said, but he had been in office for longer than most people had lived in Cobija.

“It’s time to find someone else to continue what he did,” she said after the referendum, which .

Latin American leftists like Mr. Morales have suddenly felt their longevity ebb as a tide rises against them.

But is the wave of discontent a rejection of the left? Or is it something more personal, aimed at the outsize leaders themselves, not necessarily at the ideas they have promoted?

In , former President Hugo Chávez’s movement lost by a landslide in . In , the left-wing allies of former President Cristina Fernández de Kirchner could not hold onto her office.

Ecuador’s president, Rafael Correa, a populist educated in the United States, abandoned an effort to seek another term. Corruption accusations and have left President Dilma Rousseff of battling proceedings. But while longstanding leftist leaders and their movements may be faltering, their policies have taken a lasting hold in Latin America.

Much as President Ronald Reagan and Prime Minister Margaret Thatcher took the United States and Britain down a more conservative path, leaders like Mr. Morales made a commitment to diminishing inequality that is expected to remain even as governments come and go.

“No leader in Latin America today can afford not to focus on inequality and go back to the neoliberal formulas of the 1990s,” said Michael Shifter, president of the Inter-American Dialogue, a policy institute in Washington. “Whatever criticism you might have of the leaders of the left, they put their finger on the legitimate grievance of Latin Americans: that they had been excluded from the political system.”

Map | Cobija, Bolivia

For some of the opponents now taking power, the question is not about razing the leftist models, but about making repairs and adjustments to them.

No case is more extreme than , where years of government controls over the economy and reliance on a booming diminished agricultural production to the point that the country was importing its meat, milk and rice.

Then came the perfect storm when prices sank last year, creating triple-digit inflation and food shortages. In parliamentary elections, leftists were wiped out after 16 years of control.

The opposition rose by criticizing government subsidies, but its plan focuses on cutting them for the wealthy and stabilizing them for the poor. President Nicolás Maduro, Mr. Chávez’s successor, agreed to raise the price of gasoline, reducing a subsidy seen as benefiting the car-owning wealthy. No one has suggested making changes that could harm the poor.

Argentina’s new president, Mauricio Macri, has enacted sweeping changes that have shifted the country to the center-right, including shrinking the state payroll and reducing electricity subsidies.

But Mr. Macri has maintained price control strategies intended to shield people from inflation. He also extended a child benefit program that was the cornerstone of Mrs. Kirchner’s social policy.

“Macri, as well as the rest of Latin America, now understands that it’s necessary to maintain and improve the social agenda,” said Alejandro Grisanti, a former Latin America economist at Barclays Capital.

Here in Bolivia, many point out that while Mr. Morales was blocked from running in the next election, no successor could undo his work in Cobija.

This small Amazonian rubber port became a laboratory for Mr. Morales’s project to bring the government to the country’s poor periphery. The portion of Cobija’s annual municipal budget from national gas taxes increased to $40 million today from $1.2 million in 2006, the year Mr. Morales took office, and helped underwrite a public university and a large solar plant in a place where there had been cows, jungle and dirt roads.

“I don’t know why other governments never sent any resources here before,” says Luis Adolfo Flores, the governor of Pando, the state that includes Cobija, and a member of Mr. Morales’s Movement Toward Socialism party.

Twenty years ago, Alipio Rodríguez Suárez, 74, lived in an isolated patch of jungle next to a river. Now he has hundreds of new neighbors and an asphalt road with a median in front of his house.

He also receives pension under a program established by Mr. Morales. He says the modest $36 a month covers his bills. “I can be retired now,” he said. “My parents worked in the rubber industry until they died.”

The population here has doubled to 47,000 in 10 years, an increase that includes many indigenous Aymara and Quechua people who relocated. Storefronts have opened with facades that reflect indigenous traditions. Government workers are now learning Cabibeño, an Amazonian language.

The elevation of indigenous culture — one of Mr. Morales’s trademarks — has had a lasting effect, residents say.

“The mentality of the people has changed,” said Juan Carlos Arequipa, a taxi driver in Cobija. “None of us thought we would have a satellite,” he said, referring to Bolivia’s Túpac Katari 1 satellite, built and launched by the Chinese in 2013 and named after an indigenous leader. “We have the ability to do great things.”

Yet Mr. Shifter, of the policy institute, said that development had backfired on Mr. Morales, raising expectations in an electorate that became more critical of him, especially as his presidency dragged on.

“He became a victim of his own success,” Mr. Shifter said. “People now have pride and demands.”

Corruption allegations surround the president. On Friday, the authorities arrested Gabriela Zapata Montaño, with whom Mr. Morales had a child out of wedlock. Ms. Zapata, who was the director of a Chinese company that received millions in government contracts, was under investigation in connection with peddling favors, the authorities said.

Similar complaints surfaced in Cobija, where the Evo Morales School sits empty, a $650,000 project that was never completed because a developer vanished after receiving government money. Only half of the first story was built, and vines are growing on the exposed rebar.

On Thursday, protesters here blocked a road, demanding that the city provide water, gas and electricity to a neighborhood they had created after seizing land. Mr. Morales once supported such takeovers but had not supported these people, and they wanted to know why.

“We are in the middle of a city, and we have no lights,” said María Estera, a 61-year-old teacher.

Finally an organizer said the government had relented and would begin installing electricity.

“We will have lights by 6 p.m. tomorrow,” he said to cheers.

The protest broke up.

“We have learned from Evo how to do this, and we can use it against them,” one of the demonstrators said. “When he was a peasant, this was the strategy that he used.”