US President Donald Trump on Thursday scrapped a planned meeting at the G20 summit with his Russian counterpart Vladimir Putin over Moscow's detention of a group of Ukrainian sailors.

"Based on the fact that the ships and sailors have not been returned to Ukraine from Russia, I have decided it would be best for all parties concerned to cancel my previously scheduled meeting in Argentina with President Vladimir Putin," he wrote on Twitter.

"I look forward to a meaningful Summit again as soon as this situation is resolved!," Trump added, shortly after taking off for the weekend summit in Buenos Aires.

The announcement came shortly after Trump had told reporters as he left the White House that the summit would be a "very good time" for a meeting with Putin.

"I probably will be meeting with President Putin. We haven't terminated that meeting. I was thinking about it, but we haven't. I think it's a very good time to have the meeting," he had said.

White House Press Secretary Sarah Sanders told reporters shortly after take-off Trump had conferred in person with Chief of Staff John Kelly and Secretary of State Pompeo aboard presidential plane Air Force One -- as well as by phone with National Security Advisor Bolton, who is in Brazil -- before announcing the U-turn.

"It's just happened in the last half hour," Sanders said.

Asked how Putin was informed about the cancelation, she said she was "not aware" of a phone call between the two leaders

"There was some back and forth" through other channels, she said without elaborating.