As well as talks with President Trump, Mrs May has met the premiers of China, Japan and India for one-to-one meetings during the two-day summit.
But the confirmation comes after speculation over when Trump would be making a visit, with the expectation that there could be large-scale protests when he did arrive, and the omission of any mention of a visit during the Queen's speech last month.
May said Trump made clear "that he was very keen to come to London".
Trump has made a trade agreement with the United Kingdom a higher priority, partly as a show of solidarity for British voters who chose to exit the European Union a year ago.
After the meeting with Theresa May at the G20 summit in Hanberg, Germany.
He added: "Prime Minister May and I have developed a very special relationship and I think trade will be a very big factor between our two countries".
Trump sparked worldwide anger earlier in the year when he withdrew the US from the Paris Climate Accords.
President Trump, ahead of a bilateral meeting with United Kingdom Prime Minister Theresa May, said on Saturday that the US and UK were working on a "very big" trade agreement - and added that he expected negotiations to be concluded rapidly.
Louisiana won't give voter data to feds
Larry Hogan and elections officials to vociferously reject the panel's efforts. "We understand concerns about voters' privacy". He said there was no evidence that Maryland's 2016 election, or any state's election, was compromised, and urged Gov.
Japan's new trade deal with the European Union, signed off on Thursday, "could form the basis" of an agreement between London and Tokyo following Brexit, Mrs May told the Japanese premier.
When asked about timing, he responded: "We'll work that out".
He said he had developed a "very special" relationship with the prime minister, mirroring language often used to describe the broader historic ties between the US and the UK.
Despite the agreement on trade, officials are still struggling to reach an agreement on climate change with Trump, who is at odds with the other G20 leaders after his decision last month to pull the U.S. out of the 2015 Paris climate change accord.
Christopher Meyer, a former British ambassador to Washington, said Trump's statement of intent was a "very good sign for the future" and would be "useful" to May.
May also said she was optimistic about hoped-for future trade pacts with the USA and other countries after meeting Trump at the Group of 20 summit.
As well as discussions on a future trade deal with the US, May raised Trump's controversial decision to pull out of the global Paris agreement on tackling climate change.
"I wouldn't actually believe anything actually that the Kremlin is putting out", he said.