Donald Trump sparked outcry by threatening not to defend NATO members who do not spend enough, but for diplomats at the alliance that weathered his time in office there was a sense of deja vu.

At a campaign rally in the US state of South Carolina the volatile former reality TV star said he told the leader of a "big" European power he wouldn't step in if Russia attacked an ally not meeting its financial obligations.

"No, I would not protect you. In fact, I would encourage them to do whatever the hell they want," Trump told his supporters.

The outburst was the most extreme from the Republican frontrunner casting doubt on his commitment to NATO's collective defence umbrella that has safeguarded Europe since World War II.

US President Joe Biden -- who has pledged iron-cast backing for the alliance -- slammed the comments from his likely opponent in November's presidential election as "appalling and dangerous".

NATO chief Jens Stoltenberg issued an unusually strong-worded rebuttal to Trump, saying "any suggestion that allies will not defend each other undermines all of our security, including that of the US".

The spectre of a returning Trump undermining the central role played by the US at a time Russia is waging war in Ukraine is a nightmare for many European officials.

One senior NATO diplomat, speaking like others on condition of anonymity, called the comment an "attack on the soul of the alliance" for casting doubt on its Article 5 vow to protect an ally if attacked.

But it's far from the first time that the ex-real estate magnate has bullied fellow NATO members to splash out more on their own defence.

During his term in office he reportedly mulled pulling Washington out of the alliance and rounded on members such as Germany for falling well below a target of spending two percent of GDP on defence.

"We are all aware of the statements he can make," a second diplomat from a NATO member told AFP.

The latest from Trump comes with almost nine months left in a presidential campaign that looks set to be one of the nastiest in recent US history -- and officials are braced for more nerve-wracking comments.

"Even despite the outcry, it will be understood as comments made within the context of the US election race," a third NATO diplomat said.

- Defence spending -

Officials admit that Trump sowing doubt about US support for NATO is a boon for the Kremlin as warnings swirl that Russian President Vladimir Putin could look to target alliance members if Ukraine loses the war.

Trump has previously been accused of cosying up to Putin and has cast doubt on sending more aid to Kyiv.

But multiple diplomats said that, despite his bluster, the ex-US leader does have a point on spending and has actually helped strengthen NATO by getting others to spend more.

"Worrying statement -- but at the same time many allies have not reached minimal two percent of GDP for defence," said another NATO diplomat.

"The goal seems to be obvious in current geopolitical situation, but still not yet become a reality. Europe should do more in this regard."

Moscow's seizure of Crimea from Ukraine in 2014 already pushed European nations to up defence budgets. The full-scale invasion in 2022 saw NATO turn the two percent into a floor not a ceiling.

Trump's goading sped up the process, but still in 2023 only eleven of the 31 allies were predicted to hit the target and the US still accounts for the vast bulk of combined defence expenditure.

"Forget the rhetoric, follow the money," said one NATO diplomat.

Another pointed out that, while many had feared the worst during Trump's term, his moves then resulted in a strengthened NATO.

"He invested more in the Eastern flank, basically made Europe invest more in defence, was quite calm at the summits, kept the forces in Europe," the diplomat said.

"It seems it may be just a way to make us do more. But do we have a guarantee? No."