That President Xi agreed to designate fentanyl a controlled substance, meaning that Chinese selling the powerful synthetic drug to the U.S. will be subject to maximum penalties, is also important to President Trump, who has made fighting America's raging opioid epidemic a priority. And Beijing agreed to reconsider a takeover by USA chipmaker Qualcomm that it had previously blocked. The two sides also exchanged views on the Korean Peninsula issues, according to Wang.
Mr Trump had earlier said the pair shared a "very special" relationship.
Trump has long railed against China's trade surplus with the United States, and Washington accuses Beijing of not playing fairly on trade. Trump has also threatened to add tariffs on another US$267 billion of Chinese imports.
Some $50 billion worth of Chinese imports already face 25 per cent tariffs, while the 10 per cent tariffs - which target a massive $200 billion in goods - will also remain in effect.
And that is important for President Trump as Chinese tariffs were affecting his power base, the rural heartlands of the Midwest which export commodities like soya beans and sorghum to China.
G20 declaration stresses fair, sustainable development
On Friday, Xi and leaders from the BRICS group of leading emerging economies - Brazil, Russia, India, China and South Africa - called in a statement for open worldwide trade and a strengthening of the WTO.
It was unlikely that the two countries would reach a full-blown resolution in Buenos Aires; the issues that divide them are just too hard.
The communique was in harmony with "many of the United States' biggest objectives", especially in backing reform of the World Trade Organization, according to a senior administration official who briefed reporters on the condition of anonymity. In doing so, they cited the trade conflict as well as political uncertainty. "China will be getting rid of many of them".
Some analysts said the talks had made important progress on cooperation on the North Korean nuclear program and restricting illicit Chinese shipments to the USA of the addictive opioid fentanyl, but did not represent a breakthrough in commercial diplomacy.
President Trump heralded the meeting as "amazing and productive", saying it brought about "unlimited possibilities for both the United States and China".
China nixed the proposed purchase of Dutch semiconductor manufacturer NXP by the chipmaker over antitrust concerns.
While Mr Trump has drawn praise for finally taking on China, his methods have raised fears of a deeper and wider trade war that would eventually cost more jobs than it creates.
Qualcomm announced it was dropping plans to proceed with the deal after it failed to receive Chinese government approval.
Even as Trump appeared to soften his approach to China, he talked tough on a separate trade front.
After the 2-1/2 hour meeting, White House chief economist Larry Kudlow told reporters the talks went "very well", but offered no specifics as he boarded Air Force One headed home to Washington with Trump. He said there were three sites under consideration, but he declined to name them. "Congress will have a choice of the USMCA or pre-NAFTA", he said.
The G20 groups Argentina, Australia, Brazil, Britain, Canada, China, France, Germany, India, Indonesia, Italy, Japan, Mexico, Russia, Saudi Arabia, South Africa, South Korea, Turkey, the United States and the European Union.
With the United States and China locked in an economic dispute that has unnerved global financial markets and weighed on the world economy, Trump and Xi sat down with their aides for a working dinner at the conclusion of a two-day gathering of world leaders in Buenos Aires.
Xi agreed to designate the drug fentanyl as a controlled substance, the White House said.
As per an earlier statement from the White House, the USA leader also said China would now look to buy from the US a "tremendous amount of agricultural and other products", in a bid to address the one way flow of trade.