Dmitry Medvedev, Russia's former president, has warned that Moscow's confrontation with the West will last decades and that its conflict with Ukraine could become permanent.

Medvedev, once seen in the West as a liberal moderniser, has emerged as one of Russia's most outspoken hawks since Moscow launched what it called a "special military operation" in Ukraine last year.

Now deputy head of the Security Council, his views reflect some of the thinking at the Kremlin's top level, according to Russian officials.

In an article for the government's Rossiiskaya Gazeta newspaper, he said tensions between Russia and the West were "much worse" than during the 1962 Cuban missile crisis when the world teetered on the edge of a nuclear conflagration.

A nuclear war was "quite probable" but was unlikely to have any winners, said Medvedev, who has repeatedly said Western support for Ukraine increases the chances of nuclear conflict.

He cited sharp differences over Ukraine, the direction of humankind, and the way the world order was structured.

"One thing that politicians of all stripes do not like to admit: such an Apocalypse is not only possible, but also quite probable," wrote Medvedev.

Western analysts cast what they say is Medvedev's "nuclear sabre-rattling" as a tactic aimed at frightening the West to reduce military support for Ukraine and to instead lean on Kyiv to start peace talks with Moscow.

Many countries in the West, which say they are helping Ukraine defend itself from a brutal colonial war of conquest, have promised to stand by Kyiv for as long as it takes.

The United States, Ukraine's biggest financial and military backer, has said it does not want to engage in a direct conflict with Russia to avoid the risk of a nuclear war.

Ukraine says it won't negotiate until it has driven every Russian soldier from its territory.

Medvedev said Moscow was still committed to stopping Ukraine join NATO.

"Our goal is simple - to eliminate the threat of Ukraine's membership in NATO. And we will achieve it. One way or another," he said.

Given NATO's rule about not admitting countries entangled in territorial conflicts, he said the conflict with Ukraine could become "permanent" given its existential nature for Moscow.

The only way to de-escalate tensions between Russia and the West was to enter into tough negotiations, he said.

"The confrontation will be very long and it is too late to tame the recalcitrants (i.e. us)," said Medvedev. "The confrontation will last for decades." (Reporting by Andrew Osborn Editing by Guy Faulconbridge and Frank Jack Daniel)