After struggling for months to reach a consensus on who should be the next chief prosecutor, International Criminal Court members on Friday resorted to a vote by secret ballot. After two rounds of voting, British lawyer Karim Khan was declared the winner. He will replace Fatou Bensouda, whose nine-year term ends June 15.

Khan has served in multiple international courts, including the International Criminal Tribunals for the former Yugoslavia and Rwanda, established after the Balkans conflict and the Rwandan genocide. More recently, Khan led a United Nations criminal probe into suspected war crimes, crimes against humanity and genocide by the Islamic State militant group in Iraq.

ICC member countries considered a large pool of candidates for the job of prosecutor, hoping to reach a unanimous decision. That didn’t happen. Getting 123 countries to agree on anything is difficult. Add to that the significance of the task: The court’s ability to garner convictions, investigate diverse countries and contend with powerful opponents was at stake with this choice.

Here’s what you need to know about the new prosecutor and the challenges he will face.

Khan will be the ICC’s third chief prosecutor

The ICC, created in 1998 and operational since 2002, has a mandate to investigate and prosecute individuals suspected of serious international crimes, namely war crimes, crimes against humanity and genocide. The court has many high-profile investigations underway, including an investigation into alleged U.S. war crimes in Afghanistan.

Khan will be the third chief prosecutor. The first was Argentine Luis Moreno Ocampo. Both he and Bensouda, a jurist from The Gambia, were elected unanimously by the Assembly of States Parties. The election wasn’t so easy this time.

The ICC election committee vetted 89 applicants and shortlisted four nominees — not including Khan. When member states couldn’t reach a consensus, the committee revised the slate — this time including Khan.

Who is Karim Khan?

Khan, 50, is a well-regarded lawyer with extensive experience in international justice. In his 28-year career, he has handled complex cases before multiple tribunals. He is also well acquainted with the ICC, having worked from the opposite side of the courtroom as lead defense counsel.

Khan’s most notorious past client is perhaps Kenyan Deputy President William Ruto, who was charged with crimes against humanity during the 2007-2008 post-election violence that left more than 1,000 dead. In retaliation, Ruto and President Uhuru Kenyatta led a campaign for African governments to withdraw from the ICC, accusing it of being neocolonial and biased against Africans. Ultimately, the court withdrew the charges because of insufficient evidence, and Kenya remained an ICC member.

While Khan appeared to be an early favorite, some countries voiced concerns about electing a European prosecutor, given past accusations of the court being imperialist. The election committee also noted in its candidate appraisal that, as former defense counsel, Khan would probably need to recuse himself from several cases.

Nonetheless, Khan received praise from colleagues — and an important endorsement from a coalition of African nongovernmental organizations for his “ability, leadership and integrity to address the crisis of confidence.” They also highlighted his commitment to victims.

Khan won the most votes in the first round, 59 of 123. But because he didn’t win a majority, there was a second round. He won with 72 votes.

ICC prosecutors have garnered praise and criticism

Moreno Ocampo was the ICC’s first chief prosecutor, serving from 2003 to 2012. A witness to a military dictatorship and human rights abuses in his native Argentina, he was part of the legal team that prosecuted ex-junta members in the 1980s.

At the ICC, he conducted multiple investigations, including in the Central African Republic, Democratic Republic of the Congo, Kenya and Uganda. He also indicted three sitting heads of state: Sudanese President Omar Hassan al-Bashir, Ivorian President Laurent Gbagbo and Libya’s Moammar Gaddafi.

Critics argued that Moreno Ocampo was biased against Africans. The Bashir indictment sparked conflict with the African Union, and the investigation in Kenya drew similar ire. The African Union chairman accused Moreno Ocampo of “rendering justice with double standards.”

Bensouda has been chief prosecutor since 2012. She previously served as the ICC deputy prosecutor and, before that, as justice minister in The Gambia and a legal adviser and trial attorney at the Rwanda tribunal.

She has defended the ICC against accusations of bias and widened the court’s geographic scope, opening full investigations in Georgia, Bangladesh and Myanmar, and Afghanistan. In addition, she initiated several preliminary examinations, including into suspected Israeli war crimes in the Palestinian territories. She has also been an advocate for addressing conflict violence against women and children. She has secured four convictions during her term — that is four more than her predecessor.

But her work also made her a target of criticism — and retaliation — from a number of countries, including the United States and Israel, neither of which is an ICC member. Bensouda is under a U.S. sanctions regime initiated by the Trump administration because of the Afghanistan investigation. The Biden administration has said it will review the policy.

Khan will face a balancing act

After a contentious election, all eyes will be on Khan as he assumes the top job in June. But the prosecutor-elect has a vision to revitalize the ICC. He hopes to build confidence in the court’s work by acknowledging past mistakes, making victims the central focus of the court’s work and forging cooperative partnerships with governments.

As the ICC enters its third decade, two things seem clear. First, the court is trying to be responsive to member feedback. For example, it has diversified its portfolio of investigations, which now covers 20 countries across four continents — not just Africa.

Second, the prosecutor’s conduct matters for public perceptions of the ICC. Accepting constructive criticism from member states has reduced tensions, and standing up to bullying has boosted general confidence in the court. When President Donald Trump threatened Bensouda with sanctions, for instance, she didn’t retreat. She persisted.

Starting this summer, it will be Khan’s job to balance his office’s independence with the interests of the international community and the rights of victims of serious crimes.

Nastaran Far is a former Leonard D. Schaeffer fellow in government service and a research fellow in the International Justice Lab at William & Mary.

Hailey Robertson is a researcher in the Security and Political Economy Lab at the University of Southern California and a research fellow in the International Justice Lab at William & Mary.

Kelebogile Zvobgo (@kelly_zvobgo) is provost’s fellow in the social sciences at the University of Southern California and the founder and director of the International Justice Lab at William & Mary.