Ukraine’s protest movement has turned into a revolution, complete with barricades, giant slingshots and the seizure of government buildings across a third of the country. For a still fragile nation, this is a moment of extreme danger that requires an urgent international response. Ultimately, President Viktor Yanukovych will have to leave office.

Months of peaceful protests became violent this month, after Yanukovych -- emboldened by a $15 billion Russian bailout -- drove a package of repressive laws through parliament. That was, to put it mildly, a mistake: Upset in November by Yanukovych’s decision not to sign a trade deal with the EU, his opponents now believe they are in a zero-sum struggle for basic political rights. They are being joined even in parts of the country’s traditionally pro-Russia heartland.

Who can blame them? Acts of brutality by the security forces -- including kidnapping an activist from a hospital, torturing him and then leaving him to freeze to death in a forest -- serve as a reminder that parts of Ukraine’s administration remain darkly cynical. During the 2004 presidential campaign, Yanukovych’s rival Viktor Yushchenko was, after all, disfigured by poison.

Since the protests turned violent, there has been reason to worry about ultranationalists playing a more prominent role on the opposition side, but Yanukovych’s supporters overstate this for effect. Mainly, this remains a popular uprising led by ordinary Ukrainians who think that a corrupt regime has cost them a generation of development. The deaths of as many as six protesters, the wounding of more than 1,000, as well as dozens missing haven’t dented their determination. Nor have dousings by water cannon in subzero temperatures.

Yanukovych seems to realize his miscalculation. On Friday, he attempted to compromise, offering opposition leaders the posts of prime minister and deputy prime minister, and promising to amend the recent laws criminalizing most forms of public protest -- if they would send the protesters home. A few weeks ago, this might have worked, but now it’s too late. His offer was rejected.

To end the violence, a concerted effort is required in the next few days from the opposition, the government and the international community -- especially the risk-averse EU. This dispute is no longer primarily about Ukraine’s choice of East versus West, yet any winner-takes-all result would risk splitting the country -- as a recent call by Ukrainians in the Crimean peninsula to form a new nation called Malorossiya (Little Russia) demonstrates.

Both sides can still step back: Faced with a threat that the government would declare a state of emergency, protesters on Monday abandoned the Justice Ministry building in Kiev, which they had occupied over the weekend. Ukraine’s parliament, when it reconvenes Tuesday, should repeal the package of laws that triggered the violence, as Yanukovych himself has agreed, demonstrating good faith ahead of further talks. Then, an international mediator acceptable to both sides, is required. Didier Burkhalter, the Swiss head of the Organization for Security and Cooperation in Europe, the only security body shared by Russia, the EU and the U.S., has offered. The EU should back the move, and Yanukovych and the opposition should accept.

At the same time, the EU must make clear the cost of further brutality and oppression by Yanukovych. The Ukrainian political and business leaders who support him must know that keeping him in power will mean, for them, travel bans, financial investigations and asset freezes. To demonstrate its seriousness, the EU should suspend immediately visa-free travel in Europe for Ukrainians with official service passports.

Yanukovych must choose between attempting to stay in power by brutal force and securing a soft exit for himself and his family -- through early elections, prisoner amnesties and a mediated agreement on transition. By now, Ukraine’s revolutionaries will accept nothing less.

To contact the Bloomberg View editorial board: view@bloomberg.net.