US President Donald Trump says he has spoken to Chinese President Xi Jinping and the two leaders’ teams will restart trade talks after a long lull in order to prepare for a meeting at the G20 summit later this month.

The US and China are in the middle of a costly trade war that has pressured financial markets and damaged the world economy.

Talks between the two sides to reach a broad deal broke down last month and interaction since then has been limited.

Trump has made no secret that, despite his threat to escalate the dispute with more US tariffs on Chinese goods, he would like to meet with Xi at the Group of 20 meeting in Japan next week.

In a Twitter post on Tuesday, Trump said he and his Chinese counterpart had agreed to start preparations during a phone call.

“Had a very good telephone conversation with President Xi of China. We will be having an extended meeting next week at the G-20 in Japan. Our respective teams will begin talks prior to our meeting,” Trump tweeted.

Chinese state media said Xi agreed to the meeting and emphasised in the call that economic and trade disputes should be solved through dialogue.

“The key is to show consideration to each other’s legitimate concerns,” Xi said. “We also hope that the United States treats Chinese companies fairly. I agree that the economic and trade teams of the two countries will maintain communication on how to resolve differences.”

The confirmation of a meeting avoids the possibility of a snub to Washington that could have triggered another round of tariffs.

Stocks extended gains after the tweet, with the Dow and S&P up more than one per cent, as investors bet new talks could ease trade tensions between the world’s two biggest economies.

Washington has already imposed 25 per cent tariffs on $US250 billion ($A365 billion) of Chinese goods, ranging from semi-conductors to furniture, that are imported to the US.

Trump has threatened to put tariffs on another $US325b ($A475b) of goods, covering nearly all of the remaining Chinese imports into the US, including products such as cell phones, computers and clothing.