BERLIN — Exit President Trump, offending almost everyone. Enter China, eager to talk.
In a geopolitical whirl this week, the new American president had barely left Europe to face his Russia troubles at home before Chancellor Angela Merkel, the Continent’s No. 1 leader, suggested that Mr. Trump’s America was no longer a reliably close ally.
An outcry ensued, with analysts on both sides of the Atlantic talking of an epochal shift in relations. And that was even before reports began to emerge from the White House on Wednesday that Mr. Trump was expected to withdraw from the landmark 2015 Paris climate accord.
But as Ms. Merkel’s busy diplomatic schedule this week seemed to indicate, she might have other options.
On Monday and Tuesday, Ms. Merkel hosted a big Indian government delegation, including Prime Minister Narendra Modi, whom her spokesman made a point of calling a “reliable partner.” Then, on Wednesday, the chancellor welcomed Li Keqiang, the prime minister of China.
The timing of the visits has intensified speculation that in the current febrile state of global politics, China in particular may prove a steadier ally on climate change and free trade than Mr. Trump, even if it comes with its own tensions and complexities.
“Trump’s turn away from America’s classic leading role is having a destabilizing effect,” wrote Henrik Müller, a professor at Technical University of Dortmund, in his weekly column on the global economy for Der Spiegel. “One consequence: Global economic policy is sorting out in a new way. The other two big economies — the E.U. and China — are seeking new partners to work on the international problems.”
China’s prime minister underscored Germany’s importance by stopping in its capital for two days of talks before going on to the European Union headquarters in Brussels, where Mr. Trump made such a poor impression last week.
He clearly frustrated Ms. Merkel by proving impervious to her requests, and those of other Europeans, to commit to staying in the Paris climate accord. Yet Ms. Merkel, campaigning for a fourth term from voters who cherish the environment but rarely coddle American presidents, insisted there was no rift.
But the Chinese view Mr. Trump’s harsh behavior in Europe as a gift to be capitalized on. It helps Beijing carry through on a long-term vision of China and the European Union joining together as a geostrategic balance against the United States, some Chinese analysts said.
“Possibly we will see an important shift in the China-U.S.-E.U. triangular relations, with China and the E.U. moving closer while the U.S. and E.U. drift apart,” said Wang Dong, assistant professor at the School of International Studies at Peking University. “Premier Li and Chancellor Merkel will likely reaffirm their commitments to upholding the Paris agreements.”
Baohui Zhang, professor of international relations at Lingnan University in Hong Kong, sensed major changes afoot, too. “Li should be seen from a different perspective now by his hosts,” he said. “I think Europe in general and Germany specifically are collectively experiencing a paradigm shift in their perceptions of U.S.-Europe relations.”
In Berlin, that view is shared by some analysts. Before the United States election, sharp tensions were visible between Europe and China, particularly over Chinese investment in strategic or military firms, said Björn Conrad, a leading researcher at the Mercator Institute, a Berlin think tank on China. Now, “there is a shift going on.”
“Obviously, if you feel you are losing a very important partner, you have to be on the lookout for alternatives,” Mr. Conrad said.
But that view is not universal, and others see a more calibrated calculation.
“For Berlin, the relationship with China is not a tool to achieve more influence globally,” said Volker Stanzel, a former German ambassador to both China and Japan. “Improvement of that relationship seems sensible in order to pursue Germany’s economic interests in China better,” he said, particularly at a time when China is wavering in its commitment to allow more leeway to foreign companies operating in China.
Ms. Merkel, who has visited 10 Chinese provinces in 11 years in power, insisted in Beijing last summer on reciprocity for foreign companies.
In February, Germany, France and Italy presented the European Commission with a request to set up screening of incoming foreign investment.
Germany, in particular, was concerned after Chinese investors acquired two strategic companies, the robot maker Kuka and the high-tech Aixtron, in murky deals.
The balance between security and the need for capital in a globalized world is a central concern for both Europe and Japan as they move forward with China.
The Chinese government has presented itself this year as the chief proponent of globalization as a source of prosperity — a stark divergence from Mr. Trump’s protectionist instincts and rejection of multinational trade deals over more old-fashioned bilateral accords.
President Xi Jinping of China delivered the keynote speech at the World Economic Forum in Davos, where he positioned China as the guarantor of free trade. Despite widespread criticism from Western firms and analysts of China’s failure to open up its economy, European business leaders applauded.
Next, Mr. Xi just hosted a conference in Beijing for its Belt and Road initiative, which is scheduled to bring vast Chinese-led investment in bridges, rails and ports to Europe, as well as other parts of the world.
Mr. Xi is expected to push that initiative at the next global gathering of note, the G-20 summit meeting hosted by Germany in Hamburg in early July.
China sending its two most senior leaders here twice in the space of just over a month underscores how seriously Beijing takes Germany — and Ms. Merkel, who according to current opinion polls is expected to win national elections in September.
Mr. Stanzel, the former ambassador, cautioned, however, that the frequency of meetings at many levels does not necessarily signify accord.
“We see a long process of increasing frustration with how China implements its reform plans,” he wrote in an email. That requires frequent and intense contacts “which may give the impression that they become warmer.”
Marcel Fratzscher, president of the German Institute for Economic Research, concurred that replacing America with China “is not a good swap.”
“Germany has a lot more to fear from the Chinese than from the United States,” he said on the sidelines of a conference on American-German relations that was taking place right by the Brandenburg Gate where former President Barack Obama appeared with Ms. Merkel last week before the Trump meetings in Brussels and Italy.
Mr. Fratzscher, for one, argued for more German interest in India, whose government had just arrived to attend an investment conference with Ms. Merkel in a nearby hotel. India currently ranks about 24th on the list of trading partners for export-oriented Germany, between Ireland and Finland.
This week, Ms. Merkel pledged support to get stalled talks between India and the European Union moving. India’s high customs tariffs and bureaucracy — protections it argues a developing country needs — have delayed progress for a decade.
Similarly, it remains to be seen if she can prod the Chinese to level the playing field for foreign companies and overcome the tensions between a deeper partnership with Beijing as relations with President Trump’s America sour.