The US president hailed the “very special relationship” he had developed with Theresa May as the pair met in Hamburg.
Mr Trump said he expected an agreement on new trading arrangements with Britain that was “very powerful” and would be great for both countries.
In a short break from talks to speak to the media, Donald Trump said: “I’d like to thank Prime Minister May for being with us. We have had tremendous talks, there is no country that could possibly be closer to our country.
“I want to thank Prime Minister May very much. We are working on a very big trade deal which will be great for both countries and I think we will have that done very quickly.
“We have all our great trade people with us. We have Wilber Ross, US Secretary of Commerce, great trade people. “Rex Tillerson and I had a tremendous meeting yesterday with President Putin.
“Prime Minister May and I have developed a very special relationship and I think trade will be a big factor between our two countries.” The revelation will rile European Union chiefs, who have tried to restrict the UK from discussing trade deals until Brexit is complete.
A senior Downing street official described a “very good atmosphere” throughout the 50 minute meeting and said a “significant proportion” of it was dedicated to the trading relationship.
The official said: “They agreed to prioritise work so a deal will be ready as soon as possible after Britain leaves the EU. “They pledged to examine areas now where the two countries can deepen their trade relations. The president made clear he believed the UK would thrive outside the EU.”
He said the conversation did not go into any specific detail of what a trade agreement might look like but “was talking in broad terms about the determination to get a good deal for both countries”.
Other issues discussed included China’s overproduction of steel, the Syrian ceasefire agreed by Mr Trump and Russian President Vladimir Putin and the Iran nuclear deal.
There was no mention of Mr Trump’s long-promised state visit to the UK in last month’s Queen’s Speech. Activists across the UK had promised huge protests if and when the visit went ahead.
Mr Trump said he plans to come to London but no dates were mentioned. When asked when he planned to visit Mr Trump replied: “We’ll work that out.”
The Downiing Street official said no date was being announced for a visit by Mr Trump. But he added: “The invitation has been extended and will be set out in due course.”
The President, who campaigned on an “America first” platform, has made “fair trade” a central theme of his foreign relations. He insists the US has been badly treated by other countries.
He is at odds with many of the members at the G20 after pulling out of the Paris climate change agreement, and launching a number of protectionist policies.
Mrs May ruled out renegotiating the Paris climate accord ahead of her G20 meeting with Mr Trump. The US president has said he will pull the US out of the deal but first wants to see if he can change its terms to be more favourable.
Britain did not include climate change as one of its four main objectives ahead of the summit but after arriving in Hamburg for the meeting Ms May told reporters that the Paris Agreement was non-negotiable.
Threats from the EU have not stopped Theresa May, who boosted Britain’s global trading links further yesterday when she met Chinese President Xi Jinping.
Mrs May and President Xi agreed relations between Britain and China were going through “a golden era”. A source said: “The Chinese President said that he believed the talks between Britain and the EU had got off to a positive start.
“Since the referendum, Chinese investment in the UK had increased which showed Chinese confidence in the UK.” President Xi told Mrs May that “Brexit was a very big event for the world”.
But he went on to say that a stable and prosperous UK and EU were good for the world.
Mrs May will later met Japanese prime minister Shinzo Abe to talk about trade and will also offer Japan British help on counter-terrorism and cyber security when it hosts the rugby world cup in 2019 followed by the Olympics.
Mrs May is also holding one-to-one talks with Turkish president Recep Tayyip Erdogan to discuss ways to tackle the increasing numbers of Islamic State fighters leaving Syria across its border.
Chinese President Xi Jinping hailed a “golden era” of relations between China and the UK and said an increase in investment from his nation since the Brexit vote showed its confidence in Britain during a meeting with Mrs May on Friday evening.
It comes after the first day of the summit saw Mr Trump hold talks with Russian president Vladimir Putin, which Moscow described as “very constructive”.
Newly elected French president Emmanuel Macron had earlier made his frustrations with his US counterpart clear in a private meeting of all the leaders when he hit out at Mr Trump’s America first trade policy.