BERLIN -- King Charles III won plenty of hearts during his three-day visit to Germany, his first foreign trip since ascending to the throne following the death of his mother, Elizabeth II, last year.

Charles' tour saw a number of firsts that show the importance both countries placed on it -- at a time when London and Berlin are trying to rebuild relations frayed by Britain's departure from the European Union.

German President Frank-Walter Steinmeier took the unprecedented step of welcoming Charles and Camilla, the queen consort, at the Brandenburg Gate with military honors Wednesday. A day later, Charles became the first monarch to address the Bundestag, the German parliament, stressing the long-standing close ties between both countries and the importance of future cooperation.

Observers in both Germany and the U.K. said the trip sent a strong signal about the enduring strength of British-German relations.

Jens Zimmermann, a lawmaker from Germany's center-left Social Democrats, said Charles sent a "clear message" by speaking to parliament partially in German.

"The speech in the Bundestag was very well-received," Zimmermann told The Associated Press. "It was much more political than you might have expected. It was very connecting -- I think that was very good."

In the speech, Charles emphasized that London and Berlin have provided considerable aid to Ukraine in its efforts to fend off Russia's invasion -- praise that will have been gratifying to a German government more used to claims it's not doing enough to help Kyiv. Zimmermann said Charles thanking Germans for taking in so many Ukrainians seeking shelter from the war might also be seen as a roundabout criticism of the British government's recent anti-refugee policies.

Although King Charles cannot pass legislation or directly impact British policy, the "soft power" of his visit should not be underestimated, Zimmermann said.

Others said that after the pandemic's long-distance diplomacy, in-person visits like Charles' can help deepen and renew relationships between leaders.

"I think as coronavirus has faded, we've been reminded of the value of face-to-face meetings," said Bronwen Maddox, chief executive of the Chatham House think tank.

"And it just does add something to relationships, particularly between heads of state, who are very insulated," she said. "I think it has been received very well."

Charles originally planned to visit France first, but anti-government protests there led both governments to postpone that part of his trip. The new itinerary put the focus on Germany, where Charles has family roots and the royals have long been the subject of keen interest.

That fascination was on display among the German public at Charles' appearances. Despite the wet and cold spring weather, well-wishers waited patiently to greet Charles and Camilla at their stops in Berlin and Hamburg, a city that sees itself as having a particularly close connection to Britain due to its long seafaring and trading ties.

Charles and Camilla also laid a wreath at the remains of St. Nikolai church to commemorate the more than 30,000 people, mostly German civilians, who were killed in Operation Gomorrah, the Allied bombing of Hamburg in July 1943. A boat trip and a farewell reception involving musical performances, including by a Beatles cover band and a sea shanty group, rounded off the king's visit on Friday.

Michael Kruse, a lawmaker with the pro-business Free Democrats who like Zimmermann is a member of the German-British parliamentary group, said the two countries continue to have many common economic interests despite Britain's divorce from the EU.

"The channel has widened due to Brexit," he said. "That's why the visit by Britain's head of state was all the more important."

Kruse voiced a hope shared by many in Germany, that London will find its way back into the 27-nation bloc.

"My hope is still that the British will someday recognize Brexit was a mistake and return to the EU," he said. "The door should always be open for this. Until then, we say: see you again, King Charles III."

------

Danica Kirka in London contributed.