Russian-backed separatist rebels and Ukrainian troops have been clashing in the east of the country.
Russia has also been building up troops on the border with Ukraine.
The official, Dmitry Kozak, said that Russian forces could intervene to “defend” its citizens.
“Everything depends on the scale of the conflagration,” he said.
He also warned that an escalation could mark the “beginning of the end” for Ukraine – “not a shot in the leg, but in the face”.
Russia has been increasing the number of troops at the Ukrainian border, but at the same time maintains that they should not be seen as a threat.
White House press secretary Jen Psaki said Russian troop numbers there were the highest since 2014, when the conflict in eastern Ukraine began. She described the situation as “deeply concerning”.
Russia has not detailed troop numbers, but the Ukrainian military asserted at the end of March that some 20,000 Russian troops had been moved towards Ukraine’s border. Video has emerged on social media of Russian trains moving heavy weaponry towards the region.
Clashes between Ukrainian troops and the Moscow-backed rebels inside Donbass have also increased in recent months.
The death of another Ukrainian soldier on Thursday brought the number killed this year to 25. Fifty Ukrainian troops died in the whole of last year.
For their part, the rebels said one of their fighters was killed on the same day when Ukrainian troops fired 14 mortar bombs at a village on the outskirts of the city of Donetsk.
Russian President Vladimir Putin first suggested in 2019 that Russian-speaking residents might suffer a Srebrenica-like massacre if Ukraine regained full control of Donbass without guarantees.
But there have been no reports of any such atrocity being planned.
Mr Kozak suggested the rebels could hold their own for now against Ukrainian forces as they consisted of “battle-hardened units”.