MEXICO CITY — It was only about two years ago that Mexico’s leader would not even recognize President Biden’s election victory. But on Monday, the two men were standing side by side at Mexico’s national palace, locked in a group hug with their wives.
The Mexican president, Andrés Manuel López Obrador, later called his American counterpart “a visionary president,” saying “there would be no other leader” who could unify the Western Hemisphere.
It was a remarkable turn in a critical relationship that started on uneasy footing, but has shifted in part because Mr. Biden has invested heavily in personal diplomacy with the Mexican head of state — and Mr. López Obrador has realized how beneficial it is to be on friendly terms with the United States.
Significant challenges remain pressing on both sides of the border, and the two countries are not always aligned on how to contain an extraordinary movement of people across the Americas, curb the surging trade in fentanyl or combat climate change.
The meeting between Mr. Biden, Mr. López Obrador and Prime Minister Justin Trudeau of Canada, known as the North American Leaders Summit, concluded on Tuesday without yielding much in the way of new policies. And it’s unclear whether any of the warm gestures on display at the summit will translate into more lasting cooperation on those contentious issues.
At a news conference on Tuesday evening, Mr. López Obrador stressed the importance of leaving behind “hegemonic interventionism,” saying the three countries must treat each other “as good neighbors, economic allies and as friends.”
Energy remains a sticking point, as the United States and Canada have accused Mexico of violating a free-trade agreement with policies that boost a state-owned electrical utility over international companies.
But the gathering did send a clear message: Years after former President Donald J. Trump at best neglected — and at worst battered — partnerships in North America, the United States is back on better terms with some of its closest allies.
“This trip is a good opportunity for President Biden to deepen his personal engagement with President López Obrador and Prime Minister Trudeau,” Jake Sullivan, Mr. Biden’s national security adviser, told reporters, adding: “That’s an important dimension to this.”
A crucial part of the summit, said Marcelo Ebrard, Mexico’s foreign minister, was deepening “personal relations” between the leaders.
Senior Biden administration officials have recognized that the rapport between the two leaders was key to securing deeper collaboration from Mexico’s government in stemming the historic flows of people arriving at the U.S. border.
“I’m grateful to have both of you as partners — and, might I add, friends — as we work together to realize a shared vision for North America,” Mr. Biden said to his Canadian and Mexican counterparts at Tuesday’s news conference.
Mr. Biden has been focused on building personal ties with the Mexican leader, said a senior state department official not authorized to speak publicly. The official noted that the U.S. president chose Mexico as his first trip to any country in the Western Hemisphere and that the two leaders speak regularly on the phone.
The friendly exchanges represent a notable shift from the way the relationship began.
Mr. López Obrador was among the last world leaders to congratulate Mr. Biden on his election victory in 2020, insisting on waiting “until all the legal issues are resolved.”
The first time the two men got on the phone after the election, Mr. López Obrador went out of his way to praise the “very good relationship” his country had established with Mr. Trump.
“The relationship between AMLO and Biden started off on the wrong foot,” said Martha Bárcena, who was appointed by Mr. López Obrador as Mexico’s ambassador to the United States from 2018 to 2020.
While Mr. Trump had called some Mexicans “rapists” and threatened America’s closest economic partner with a trade war, he adhered to at least one principle that Mexico’s leader valued: mostly staying out of the country’s business.
Mr. Trump did effectively browbeat Mexico into accepting a large number of migrants expelled from the United States, but in turn, he left Mr. López Obrador to pursue an ambitious domestic agenda without saying much about the sometimes damaging effect on American interests.
Mr. López Obrador feared that largely hands-off approach would change with Mr. Biden, partly because the Mexican leader saw Democrats as more interested in imposing their values on Latin American countries, current and former officials from both countries said.
In the run up to the last meeting between the three North American leaders, in November 2021, Mr. López Obrador attacked the Biden administration for funding Mexican media groups that he described as “opposition publications” and called the long-running American embargo on Cuba “vile.”
Then, in June, he snubbed Mr. Biden by refusing to attend a gathering of leaders from across the Americas that was hosted by the administration in Los Angeles, because Cuba, Venezuela and Nicaragua had not been invited.
But in recent months, Mr. López Obrador’s stance has appeared to soften. The Mexican leader, in his morning news conferences, has spoken about Mr. Biden in glowing terms, praising him as “responsible, sensible” and “respectful.”
What changed? Analysts point to Republicans’ disappointing showing in the midterms and Mr. Biden’s recovery in public opinion polls, a sign that the U.S. president might be politically stronger than many in Mexico expected.
More urgent for Mexico’s leader, though, are elections in his own country. This year will mark the beginning of campaigns for the 2024 presidential contest in Mexico, in which Mr. López Obrador’s is barred from running again. But he is expected to have significant say in who from his Morena party will run to succeed him— and fight to cement his legacy with another six-year term.
The Mexican president recognizes that the U.S. administration — which holds enormous economic and political sway in Mexico — could make it difficult to carry out the sweeping changes he promised to bring to the country after winning an overwhelming victory in 2018.
For Mr. López Obrador, it is now more valuable than ever to extinguish any whiff of antagonism between the two governments.
“He doesn’t want the U.S. government to be supportive of the opposition — or an open critic of his policies,” Ms. Bárcena said. “It’s smarter to be on better terms with the U.S. government than how he was at the beginning.”
Mr. Biden has also made a concerted effort to charm Mr. López Obrador. Six weeks after Mr. Biden took office, he and Mr. Lopez Obrador held their first virtual meeting, where the American president heaped praise on his counterpart, saying that “what you do in Mexico” affects the whole hemisphere.
Last summer, after Mr. López Obrador refused to attend the regional summit hosted by the administration, Mr. Biden made a public show of bringing his counterpart to the White House.
At that meeting, Mr. López Obrador told Mr. Biden that “we trust you because you respect our sovereignty.”
Blanca Heredia, a professor at Mexico’s Center for Research and Teaching in Economics, said, the two leaders “were like a couple that at the beginning didn’t know how to dance together, but then started synchronizing.”
“It’s not just that it’s better for them not to fight,’’ she added, “it’s that they both are indispensable to one another.”
This week, Mr. Biden made another modest, but important gesture: He bypassed Mexico City’s major international airport and instead flew into a smaller airport the Mexican leader’s administration had built.
Though it has been criticized as a boondoggle pet project of the president’s, Mr. López Obrador counts the new airport as a monument to his success in transforming the country and had requested that Mr. Biden land there.
After descending from Air Force One on Sunday, Mr. Biden took the display up a notch: He invited his Mexican counterpart to ride with him in his limousine on a trip to the capital made extraordinarily long by the airport’s remoteness.
For Mr. Biden, landing an hour away from the capital was a small price to pay for placating a leader whose cooperation — on migration, energy and trade — is more important than ever.
“For AMLO this is a get, being seen as respected by the U.S. president for his vision of policymaking, for his leadership,” said Shannon O’Neil, a Mexico expert at the Council on Foreign Relations. “The bet by the U.S. is, we’ll give him the optics, and then he’ll be more amenable to give us the substance.”
The ride from the airport, said Mr. Sullivan, gave the two leaders “the chance to just have a one-on-one chat,” about “how they’re seeing the world right now, what’s on their minds. I think they both got a lot out of it.”
Mr. López Obrador raved about how the American president “himself showed me how the buttons worked,” the Mexican leader said, referring to the vehicle’s controls. “President Biden is a friendly person.”