In a special televised address on state TV, Putin told the Ukrainian military to lay down its weapons and go home.
"I urge you to immediately lay down your weapons and go home. All servicemen of the Ukrainian army who fulfil this demand will be able to freely leave the combat zone and return to their families," said Putin.
The Russian leader said Moscow has been left with no choice but to launch the operation, the scope of which was not immediately clear.
"I have decided to conduct a special military operation," said Putin.
"Its goal is to protect people who have been subjected to bullying and genocide... for the last eight years. And for this we will strive for the demilitarisation and denazification of Ukraine.
"And to bring to court those who committed numerous bloody crimes against civilians, including against citizens of the Russian Federation."
Ukraine dismisses as invented Russian accusations of genocide against people living in parts of its east seized by Russian-backed separatists in 2014. Kyiv has said Putin was looking for an artificial pretext to attack it.
Putin's announcement followed an appeal from the Russian-backed separatists in eastern Ukraine for military help against what they said was growing Ukrainian aggression. Kyiv has denied any such aggression.
A Reuters reporter in Kyiv, the Ukrainian capital, heard explosions that sounded like artillery shelling in the distance minutes after Putin finished speaking.
"Russia cannot feel safe, develop, and exist with a constant threat emanating from the territory of modern Ukraine," Putin said.
Russia would respond instantly if any external force tried to interfere with its actions, he added.
"No one should have any doubt that a direct attack on our country will lead to defeat and terrible consequences for any potential aggressor," he said.
"All responsibility for bloodshed will be on the conscience of the ruling 'regime' in Ukraine," Putin told state television.
Putin's comments come after the United States said Russia had stationed nearly 150,000 troops near Ukraine's borders.
Putin repeated complaints he had made in the past about the failure of NATO and the United States to satisfy Russia's security demands.
(Reporting by Andrew Osborn, Polina Nikolskaya, David Ljunggren, Olzhas Auyezov; Maria Tsvetkova; Editing by Andrew Osborn)