Trump had tweeted US companies were "ordered to immediately start looking for an alternative to China."

US President Donald Trump on Sunday rowed back from a suggestion made just hours earlier that he regrets his trade war with China, saying instead he's only sorry not to have raised tariffs even higher.

Trump's spokeswoman Stephanie Grisham told reporters at the G7 summit in the French resort of Biarritz that the president's earlier comments had been misunderstood.

"The president was asked if he had 'any second thought on escalating the trade war with China'. His answer has been greatly misinterpreted," she said.

"President Trump responded in the affirmative -- because he regrets not raising the tariffs higher."

Earlier on Sunday, Trump appeared to signal he might be considering a softening of his position in the trade war, which has seen Washington impose steep levies on all Chinese imports -- and China responding with billions of dollars of tariffs of its own.

"I have second thoughts about everything," he said.

He also said he would hold off for now on declaring a national emergency which would allow him to invoke an obscure law that he says gives him the power to order US companies out of China.

"I have the right to, if I want. I could declare a national emergency," he said. "I have no plan right now."

Trump first brandished the possibility of the drastic measure on Friday, when he tweeted that American companies "are hereby ordered to immediately start looking for an alternative to China."