Obama warns Europe: 'Crude' nationalism led to a bloodbath
US President Barack Obama inspects the presidental guard in Athens on November 15, 2016 (AFP Photo/Louisa Gouliamaki)

US President Barack Obama issued a warning against "crude" nationalism as he kicked off his last foreign tour Tuesday with allied nations on edge after Donald Trump's shock election win.

Speaking in Greece, Obama called the NATO alliance "absolutely vital" to US interests and stressed a strong, unified Europe was good for America, in comments directed at nations jittery over Trump's campaign comments about transatlantic ties.

After a year of populist shocks, from Britain's vote to leave the EU to Trump's surprise win last week and the rise of anti-migrant movements in Europe, Obama cautioned against succumbing to divisive instincts.

"We are going to have to guard against a rise in a crude sort of nationalism or ethnic identity or tribalism that is built around an 'us' and a 'them'," Obama said in Athens.

"We know what happens when Europeans start dividing themselves up... the 20th century was a bloodbath," he said, adding that the United States was also painfully aware of the dangers of "(dividing) ourselves along lines of race or religion or ethnicity."

European governments, especially eastern countries close to Russia's orbit, have been shaken after Trump appeared to call into question Washington's near 70-year security guarantee by saying he would only help NATO allies if they paid their way.

Obama stressed that the transatlantic relationship was the "cornerstone of our mutual security as well as prosperity" and that was the case regardless of who was sitting in the Oval Office.

"Across Democratic and Republican administrations there is a recognition that the NATO alliance is absolutely vital," he said.

As Obama touched down in Athens, NATO head Jens Stoltenberg said he was confident Trump would "live up to all the commitments of the United States in the alliance -- because a strong NATO is important for Europe but it's also important for the United States."

- Alternative to austerity -

Obama met Prime Minister Alexis Tsipras for talks and praised Greece for showing "extraordinary compassion" to hundreds of thousands of people arriving in Europe's migrant crisis.

More than 800,000 migrants passed through Greece in 2015, and the crisis-hit country has struggled to accommodate some 60,000 left stranded on its territory when Balkan states further north closed their borders earlier this year.

Greek leaders are anxious for a new US pledge to help alleviate the country's enormous public debt, a measure actively sought by the International Monetary Fund but opposed by leading European lender Germany.

Obama, who travels to Germany on Wednesday for talks with Chancellor Angela Merkel and French and British leaders, said he would push for help for Greece.

"In my message to the rest of Europe I will continue to emphasise our view that austerity alone cannot deliver prosperity," Obama told Tsipras.

Even with structural reforms, he argued, "it is very difficult to imagine the kind of growth strategy that is needed, without some debt relief mechanism...(although) the politics of (doing) this are difficult."

- Mixed welcome for Obama -

Security was tight in central Athens, with thousands of police officers on the streets and an official ban on demonstrations in areas of the capital where Obama was to hold meetings during the two-day stay.

Some 2,500 people brandishing banners denouncing US "imperialism" and calling Obama "non grata", or not welcome, were turned away by police firing tear gas and stun grenades as they tried to breach barriers and head toward the city centre.

Many Greeks are suspicious of the United States after it helped install a repressive dictatorship in the country in the 1960s, and some trade unions, leftist and anarchist parties denounce US involvement in wars in the Middle East.

Several hundred of the protesters appeared to be from Greece's vocal anarchist movement, police told AFP.

The increased security for Obama's visit comes after assailants threw a grenade at the French embassy in Athens last week, slightly wounding an officer. A far-left group, the Organisation of Revolutionary Autodefence, claimed responsibility.

After Germany, Obama concludes his trip with a stop in Peru for a summit of the Asia-Pacific Economic Cooperation forum (APEC) where he is expected to meet Chinese President Xi Jinping.