Medvedev, who now is the deputy chairman of Russia's Security Council, wrote in a Telegram post that such an escalation would be a "catastrophic scenario for everyone."
"The pumping of Ukraine by NATO countries with weapons, the training of its troops to use Western equipment, the dispatch of mercenaries and the conduct of exercises by the countries of the Alliance near our borders increase the likelihood of a direct and open conflict between NATO and Russia instead of their 'war by proxy,'" he said.
"Such a conflict always has the risk of turning into a full-fledged nuclear war," Medvedev added.
"You just need to think about the possible consequences of your actions," he also wrote in the post.
The message comes about a week after Russia's Foreign Ministry claimed Moscow will not unleash nuclear weapons during the war in Ukraine despite top officials' threatening rhetoric.
Comment: Russia has repeatedly highlighted its doctrine on the use of nukes, that they will only be used if directly threatened by nuclear attack, the US on the other hand have proven their willingness to use nukes on a civilian population who posed no threat at all to them - and twice - in Hiroshima, and Nagasaki, Japan.
Alexei Zaitsev said last Friday that "we have repeatedly refuted insinuations about Russia's possible use of nuclear weapons in the course of the special military operation in Ukraine," which has now lasted 78 days.
"Russia adheres to the principal that there can be no winners in a nuclear war and it must not be unleashed," Zaitsev added, according to a translation from Reuters.