TO MANY Ukrainians, the calculations of President Viktor Yanukovych might seem baffling. Having triggered a mass protest movement by turning his back on an association agreement between Ukraine and the European Union, the president looked like he might outlast the protesters after accepting a massive bailout from Russian President Vladi­mir Putin. Yet now Mr. Yanukovych has managed to revive and intensify the rebellion against him by ramming a series of measures through parliament aimed at outlawing opposition demonstrations. Tens of thousands gathered in the center of Kiev on Sunday, and clashes with police left hundreds injured.

Perhaps Mr. Yanukovych has no sense for Ukrainian politics, despite more than a decade of leading one of its major parties. Or perhaps he is following not his own playbook but that of Mr. Putin. The repressive new restrictions, which criminalize such activity as wearing helmets and setting up tents in public spaces, look a lot like the strategy the Russian ruler used to crush mass demonstrations against his regime in 2011 and 2012. Mr. Yanukovych even adopted the regulation Russia imposed on nongovernment groups that receive foreign funding — a product of Mr. Putin’s paranoid conviction that pro-democracy movements in his country and elsewhere are the result of Western government plots.

This isn’t the first time Mr. Yanukovych has allowed Mr. Putin to be his puppeteer. In 2004 he was a candidate for president in an election that Russia’s secret services tried to rig in the way they fix votes at home. The result was the Orange Revolution, a massive uprising that overturned the fraud and left Mr. Yanukovych in the political wilderness until he agreed to play by democratic rules. It’s not clear that the current protests can have the same result — in part because some opposition militants, bolstered by government-sponsored provocateurs, have attacked police and burned vehicles, tarnishing the previously peaceful character of the protest movement.

Western governments cannot control events in Ukraine, whatever Mr. Putin may think. But they could be doing much more than they are to prevent a nation that was headed toward integration with the democratic West from becoming an autocratic Kremlin colony, like neighboring Belarus. Demoralized European Union leaders seem to have abandoned Ukraine at just the moment they should be acting to stop Mr. Yanukovych’s repression. They could do so by preparing sanctions against the president and his circle to be applied if violence is used against the protesters and by dispatching a special envoy to press both sides to take seriously what so far are desultory negotiations.

The Obama administration has been a little more active, calling on Mr. Yanukovych to repeal the anti-protest legislation and hinting that sanctions may be forthcoming. But Washington also ought to recognize Mr. Putin’s role in attempting to impose his autocratic model on a country that has been struggling to become a genuine democracy — and hold him accountable for it.