President Trump abruptly announced Friday that he was withdrawing sanctions on North Korea, immediately after his own Treasury Department imposed them.

“It was announced today by the U.S. Treasury that additional large scale Sanctions would be added to those already existing Sanctions on North Korea. I have today ordered the withdrawal of those additional Sanctions!” Trump tweeted Friday afternoon.

This was an apparent reference to sanctions the Treasury Department had announced Thursday on Chinese shipping companies doing business with North Korea. Those sanctions prompted swift pushback from the Chinese and North Korean governments.

TRUMP ADMINISTRATION SLAPS NEW SANCTIONS ON IRAN

When asked about the president’s tweet, White House Press Secretary Sarah Sanders said: “President Trump likes Chairman Kim and he doesn’t think these sanctions will be necessary.”

The Treasury Department did not immediately respond to Fox News’ request for comment.

The president's unusual move comes after his second summit with North Korean leader Kim Jong Un, held last month in Hanoi, Vietnam. Trump walked out of that summit after refusing to agree to the North’s demands of lifting all sanctions.

In what had been a move to ratchet up pressure further, the Treasury Department on Thursday had imposed the sanctions on two Chinese-based companies to highlight “the deceptive methods that the North Korean regime uses to circumvent international and U.S. sanctions, as well as the U.S. Government’s commitment to implement existing UN Security Council resolutions.”

“The United States and our like-minded partners remain committed to achieving the final, fully verified denuclearization of North Korea and believe that the full implementation of North Korea-related UN Security Council resolutions is crucial to a successful outcome,” said Treasury Secretary Steven T. Mnuchin said in a statement Thursday. “Treasury will continue to enforce our sanctions, and we are making it explicitly clear that shipping companies employing deceptive tactics to mask illicit trade with North Korea expose themselves to great risk.”

KIM JONG UN WILLING TO SIT DOWN WITH TRUMP AGAIN, NORTH KOREA STATE MEDIA SAYS

On Friday, the Chinese foreign ministry pushed back on the sanctions, saying that they “resolutely oppose any country imposing unilateral sanctions and long-armed jurisdiction over Chinese entities under its own domestic laws.”

“We have made solemn complaints with the U.S. on this matter, urging the U.S. to immediately stop such mistakes, so as not to affect the cooperation between the two sides on relevant issues,” the Chinese Foreign Ministry said, adding that any Chinese enterprises and individuals would be investigated according to China’s laws.

Fox News' Kellianne Jones, Kristin Brown and David Nath contributed to this report.