It appears that the reign of one of the world’s worst rulers is finally over.

The military of Zimbabwe began moving into the nation’s capital of Harare on Tuesday, and appeared Wednesday morning to have deposed President Robert Mugabe, who has misruled his southern African country since it achieved independence in 1980.

The coup is the latest development in a yearslong succession battle within the ruling party, the Zimbabwe African National Union-Patriotic Front, or ZANU-PF.

As I explored in a Heritage Foundation report last year, the 93-year-old Mugabe’s increasingly frail health loosened his grip on power and precipitated the internecine competition.

Since then, rifts between the military—traditionally a staunch Mugabe ally—and Mugabe himself, deepened. The final straw was likely Mugabe’s firing earlier this month of Vice President Emmerson Mnangagwa, a veteran of the war of independence with close ties to the military.

Mnangagwa’s firing cleared the way for Mugabe’s secretary-turned-mistress-turned-wife-turned-politician, Grace, to succeed Mugabe.

Grace Mugabe is almost certainly unpalatable to the military. She and her faction (known as “Generation 40,” or “G40”) are mostly too young to have fought in the war for independence (waged 1964-1979), a key credential in the military’s eyes.

Grace Mugabe, 52, also led the purges of officials with military ties: Mnangagwa and another senior party official, Joice Mujuru, a hero of the anti-colonial struggle. There are rumors that the military arrested a number of G40 leaders when it swooped into Harare.

Even when it’s by means of a coup, it is impossible to lament the toppling of a president as awful as Robert Mugabe and his apparent preferred successor, his wife, who is equally appalling.

Mugabe is ruthless, having oppressed his political opponents and brought economic ruin on a once-prosperous country. The first lady’s profligate spending habits in the midst of Zimbabwe’s economic disaster earned her the derisive moniker “Gucci Grace,” and her obsessive pursuit of power within ZANU-PF was a demonstration of the sort of ruler she would have been had she attained full power.

However, there are no guarantees that whoever ultimately replaces Mugabe will be a significant improvement.

The military was a strong base of support for Mugabe, and only flipped when its preferred successor, Mnangagwa, lost out to the first lady. No one should see the Zimbabwean military as a defender of democracy and human rights in Zimbabwe.

There are also rumors that the military might install Mnangagwa as president of an interim government. Mnangagwa was the architect of the Gukurahundi massacre campaign from 1983 to 1987 against the Ndebele tribe, which supported Mugabe’s primary political rival. His history demonstrates his ruthlessness (as does his nickname, “The Crocodile”) and his disinterest in democratic governance.

Mujuru, now a prominent opposition leader since her being purged, could potentially play a role in whatever governance arrangement emerges from the coup. Yet she also was a longtime ZANU-PF stalwart, and only decried her party’s extraordinary crimes once it was in her interests to do so.

The Zimbabwean political opposition has a number of competent figures, but is badly fractured. Morgan Tsvangirai, the longtime leader of the primary opposition group, the Movement for Democratic Change, might join Mnangagwa in a transitional government. Yet he is ill and probably lacks the standing to unify the opposition.

As well-deserved—and long overdue—as Mugabe’s ouster is, it will not necessarily translate into a free and peaceful Zimbabwe. That will require the Zimbabwean people, for the first time since independence, having a genuine say in the ruling of their country.

There is reason to hope that Mugabe’s downfall is the start of that process, but it is a long, difficult, and uncertain road ahead.