Japan and the European Union should agree to a free trade pact that could be completed within months, after senior officials removed final snags to a political deal intended as a signal to US President Donald Trump.

“We ironed out the few remaining differences,” European Trade Commissioner Cecilia Malmstrom said after a meeting on Wednesday with Japanese Foreign Minister Fumio Kishida.

Prime Minister Shinzo Abe should now sign the “political agreement” with EU institutional chiefs Jean-Claude Juncker and Donald Tusk in Brussels.

The three men will then head to a G20 summit in Hamburg, where the EU and Japan will urge Trump not to weaken US free trade traditions.

Summit host Angela Merkel, the German Chancellor, took aim at Trump on Wednesday, saying: “While we are looking at the possibilities of cooperation to benefit everyone, globalisation is seen by the American administration more as a process that is not about a win-win situation but about winners and losers.”

Japan, which lost out when Trump pulled the US out of the Trans Pacific Partnership (TPP) trade accord, and the EU, which has seen talks on a US trade deal called TTIP lapse into limbo, both see their accord as striking a blow against a feared increase in nationalistic protectionism.

“Leaders will stress their commitment to promote an open and fair global economy and refrain from all forms of protectionism,” the European Council said.

We agreed on almost everything that is important for either side

Germany’s Chambers of Commerce hailed the “symbolic power” of a deal with Japan, saying it would not only bring economic benefits in itself but also benefit world trade policy.

Senior EU officials acknowledged that it would take months to complete the full EU-Japan Economic Partnership Agreement, with not just legal technicalities but also some substantive negotiations still outstanding.

However, one insisted, “We agreed on almost everything that is important for either side.”

Details have yet to be confirmed and it is unclear how much detail yesterday’s political agreement will contain, but officials on both sides say differences have narrowed or disappeared in thorny areas including cars, where Europeans wanted to keep tariffs, and food, especially cheese, where Japan’s protected dairy industry feared exposure to EU imports.

The European carmakers’ lobby had called for at least seven years to phase out tariffs of up to 10 percent on Japanese cars, and a senior EU official said they would “not be disappointed”.

More than 200 European products that benefit from geographic protections – for example Parma smoked ham must come from around the Italian city – would not face Japanese competition under those names, he added.

Scotch whisky might not benefit from such a deal as Britain will be leaving the EU in 2019.

Most EU food exports to Japan would see tariffs removed over time, the official said, although in some sensitive sectors such as cheese and other dairy products they would be limited by quota.

Japan would make it much easier for European firms to tender for public contracts. There remain differences over how disputes under the trade agreement should be settled, he added.

That could be significant as increasingly ambitious EU trade deals have faced vocal opposition, notably on the European left, over concerns that they give multinational corporations too much clout over national regulators.

A deal with Canada nearly came unstuck last year when one small Belgian region refused to ratify it. Brussels is pushing Japan to accept an arbitration system less likely to meet opposition from European lawmakers.

Sign up to our free newsletters

Get the best updates straight to your inbox:
Please select at least one mailing list.

You can unsubscribe at any time by clicking the link in the footer of our emails. We use Mailchimp as our marketing platform. By subscribing, you acknowledge that your information will be transferred to Mailchimp for processing.