FEW pages of history are as hard to read as those describing Rwanda between April and July in 1994. Working by hand rather than with the industrial methods that the Nazis used to kill Jews, and at more than three times the speed of the Holocaust, militias known as Interahamwe from the ethnic Hutu majority, and others, slaughtered at least 800,000 Tutsis (and Hutu moderates) to remove them from shared land. They raped, tortured and dismembered in hospitals, schools and churches. “The Interahamwe made a habit of killing young Tutsi children, in front of their parents, by first cutting off one arm, then the other,” a UN official in the country recounted afterwards. “They would then gash the neck with a machete to bleed the child slowly to death but, while they were still alive, they would cut off the private parts and throw them at the faces of the terrified parents who would then be murdered with slightly greater dispatch.”

On April 7th Rwandans will mark the 20th anniversary of the genocide sombrely and peacefully. Their Tutsi-led government stands out for its competence. Around 90% of Kenyans and South Africans worry about corruption; in Rwanda the share is 5%. Life expectancy is twice as high as before the genocide. The economy grows year after year at more than 8%. Though Tutsis are the biggest beneficiaries, Hutus are not excluded.

Memories linger. The rainy season, which coincided with the genocide in 1994, is hard, not least since skeletal remains still poke out of the ground after downpours. But Rwanda’s terrible history dominates neither public life nor private conversation as it did even a decade ago.

South Africa, which celebrates the 20th anniversary of its first post-apartheid poll on April 27th, has also moved a long way from its hate-filled past. Race remains a delicate subject. Unemployment is severe and the rate of violent crime sky-high. But the campaign for the general election on May 7th is a display of self-confident democracy in action: a carnival of banners and bombastic prayers, with a record number of parties on the ballot.

Some societies manage to heal the deepest of wounds. As well as the humdrum work of disarming combatants, repatriating refugees and so on, those that succeed also pursue three more ambitious aims: the commemoration of the victims, economic development and (temporarily) the restraint of social divisions.

Commemoration reassures survivors, and all those who doubt the sincerity or durability of peace agreements. Without it, re-establishing intercommunal relations is hard. The bodies of thousands of Tamils killed by Sinhalese forces in 2009 have never been given a decent burial, poisoning Sri Lanka’s politics. Few have been as diligent as the Germans, who created a compound noun, Vergangenheitsbewältigung, which roughly translates as “the struggle to come to terms with the past”. Any lingering anti-Semitism is roundly condemned by politicians and other public figures. After building a Holocaust memorial in Berlin’s government quarter and rebuilding synagogues, Germany now has one of the world’s fastest-growing Jewish communities. “Jews here feel not just welcome, but understood,” says John Feinstein, a transplant from New York.

The chance of a share in new prosperity can help draw warring groups closer—though it is not enough on its own. After decades of hostilities, bush fighters from Renamo and Frelimo, rival factions in Mozambique, struck an on-and-off peace deal in the hope of economic benefits. But repeated promises of a “peace dividend”, with economic growth and a boom in foreign investment, were never enough to bring an end to Sri Lanka’s long civil war.

Most nations that heal well are functioning democracies. Day-to-day negotiations in a legislature chip away at the zero-sum mentality of the battlefield. Northern Ireland’s hard men now sit together at the cabinet table, seemingly with relative ease.

But enforcing new norms to replace those that drove the conflict can require measures that in other circumstances would be illiberal. Until recently, Germany banned reprints of Hitler’s manifesto, “Mein Kampf”. (Internet downloads and its copyright ending changed officials’ minds.) Philosophers talk of the “paradox of tolerance”: that upholding tolerant values may require intolerance of bigots. John Rawls, a liberal American philosopher, argued that keeping an endangered group safe may justify a measure of intolerance.

Rwanda has far overstepped this mark. It is an autocracy, though one run by often reasonable Tutsis with an understandable fear of the génocidaires regaining power. At the last presidential election Paul Kagame, who led the rebel forces that defeated the Interahamwe 20 years ago, received 93% of the vote. He has turned out to be an impressive technocrat—but one who brands his opponents, including some former allies, enemies of the state. South Africa has accused him of sending assassins to kill dissidents living in exile in Johannesburg. Independent parties and media are cowed by the security forces.

For now, this illiberalism coexists with social peace. Kigali, Rwanda’s capital, is one of Africa’s safest cities. But it risks sowing the seeds of a new conflict, either among the Hutu extremists who still populate the forests of Congo across the border to the west, or within the Tutsi camp, once known for its cohesion and discipline but now increasingly divided.

Where a post-conflict country remains intact, so that former mortal enemies are forced to live together, new leaders must choose between justice and reconciliation. South Africa opted for organised leniency; perpetrators who gave accounts of their actions to the Truth and Reconciliation Commission were eligible to apply for an amnesty. Much goodwill flowed from the proceedings. But many bloodied societies reject the very idea. The UN noted in a report that “in Kosovo, the very word ‘reconciliation’ is so charged for the Albanian community that it is simply not used.”

Rwanda initially sought mass prosecutions. At one point 120,000 alleged génocidaires were locked up awaiting trial. The worst villains were judged at an international tribunal, held in Tanzania, but most were eventually sent to home-grown lay tribunals when the national courts could not cope. Punishments were doled out unevenly. By now, many killers have returned home and the government wants to move on, though most Rwandans struggle with the notions of forgiveness and repentance.