Ayman al-Zawahiri succeeded Osama bin Laden as al-Qaeda leader after years as its main organiser and strategist, but his lack of charisma and competition from rival militants Islamic State hobbled his ability to inspire spectacular attacks on the West.
Zawahiri, 71, was killed in a US drone strike, US President Joe Biden said on live television on Monday evening. US officials said the attack took place on Sunday in the Afghan capital Kabul.
He had watched in dismay as al-Qaeda was effectively sidelined by the 2011 Arab revolts, launched mainly by middle class activists and intellectuals opposed to decades of autocracy.
In the years following bin Laden's death, US air strikes killed a succession of Zawahiri's deputies, weakening the veteran Egyptian militant's ability to coordinate globally.
Despite a reputation as an inflexible and combative personality, Zawahiri managed to nurture loosely affiliated groups around the world that grew to wage devastating local insurgencies, some of them rooted in turmoil arising from the Arab Spring. The violence destabilised a number of countries across Asia, Africa and the Middle East.
But al-Qaeda's days as the centrally directed, hierarchical network of plotters that attacked the United States on Sept. 11, 2001, were long gone. Instead, militancy returned to its roots in local-level conflicts, driven by a mix of local grievances and incitement by transnational jihadi networks using social media.
Zawahiri's origins in Islamist militancy went back decades.
The first time the world heard of him was when he stood in a courtroom cage after the assassination of Egyptian President Anwar al-Sadat in 1981.
"We have sacrificed and we are still ready for more sacrifices until the victory of Islam," shouted Zawahiri, wearing a white robe, as fellow defendants enraged by Sadat's peace treaty with Israel chanted slogans.
Zawahiri served a three-year jail term for illegal arms possession, but was acquitted of the main charges.
A trained surgeon - one of his pseudonyms was The Doctor - Zawahiri went to Pakistan on his release where he worked with the Red Crescent treating Islamist mujahideen guerrillas wounded in Afghanistan fighting Soviet forces.
During that period, he became acquainted with bin Laden, a wealthy Saudi who had joined the Afghan resistance.
Taking over the leadership of Islamic Jihad in Egypt in 1993, Zawahiri was a leading figure in a campaign in the mid-1990s to overthrow the government and set up a purist Islamic state. More than 1,200 Egyptians were killed.
Egyptian authorities mounted a crackdown on Islamic Jihad after an assassination attempt on President Hosni Mubarak in June of 1995 in Addis Ababa. The greying, white-turbaned Zawahiri responded by ordering a 1995 attack on the Egyptian embassy in Islamabad. Two cars filled with explosives rammed through the compound's gates, killing 16 people.
In 1999, an Egyptian military court sentenced Zawahiri to death in absentia. By then he was living the spartan life of a militant after helping Bin Laden to form al-Qaeda.
A videotape aired by Al Jazeera in 2003 showed the two men walking on a rocky mountainside - an image that Western intelligence hoped would provide clues on their whereabouts.
THREATS OF GLOBAL JIHAD
For years Zawahiri was believed to be hiding along the forbidding border between Pakistan and Afghanistan.He assumed leadership of al-Qaeda in 2011 after US Navy Seals killed bin Laden in his hideout in Pakistan. Since then he repeatedly called for global jihad, with an Ak-47 as his side during video messages.
In a eulogy for bin Laden, Zawahiri promised to pursue attacks on the West, recalling the Saudi-born militant’s threat that "you will not dream of security until we live it as a reality and until you leave the lands of the Muslims".
As it turned out, the emergence of the even more hardline Islamic State in 2014-2019 in Iraq and Syria drew as much, if not more, attention from Western counter-terrorism authorities.
Zawahiri often tried to stir passions among Muslims by commenting online about sensitive issues such as US policies in the Middle East or Israeli actions against Palestinians, but his delivery was seen as lacking bin Laden's magnetism.
On a practical level, Zawahiri is believed to have been involved in some of al-Qaeda's biggest operations, helping organise the 2001 attacks, when airliners hijacked by al-Qaeda were used to kill 3,000 people in the United States.
He was indicted for his alleged role in the 1998 bombings of the US embassies in Kenya and Tanzania. The FBI put a $25 million bounty on his head on its most wanted list.
Zawahiri did not emerge from Cairo's slums, like others drawn to militant groups who promised a noble cause. Born in 1951 to a prominent Cairo family, Zawahiri was a grandson of the grand imam of Al Azhar, one of Islam's most important mosques.
Zawahiri was raised in Cairo’s leafy Maadi suburb, a place favoured by expatriates from the Western nations he railed against. The son of a pharmacology professor, Zawahiri first embraced Islamic fundamentalism at the age of 15.
He was inspired by the revolutionary ideas of Egyptian writer Sayyid Qutb, an Islamist executed in 1966 on charges of trying to overthrow the state.
People who studied with Zawahiri at Cairo University’s Faculty of Medicine in the 1970s describe a lively young man who went to the cinema, listened to music and joked with friends.
“When he came out of prison he was a completely different person,” said a doctor who studied with Zawahiri and declined to be named.
In the courtroom cage after the assassination of Sadat at a military parade, Zawahiri addressed the international press, saying militants had suffered from severe torture including whippings and attacks by wild dogs in prison.
"They arrested the wives, the mothers, the fathers, the sisters and the sons in a trial to put the psychological pressure on these innocent prisoners," he said, firing up a wild-eyed man beside him and other militants.
Fellow prisoners said those conditions further radicalised Zawahiri and set him on his path to global jihad.