For over a decade now, there's been a surge in the activities of extremist groups in East and West Africa, the Sahel and parts of southern Africa.
Many are Islamist militant groups with some form of affiliation to al-Qaeda, an organization the United Nations (UN) has said shares links with the Taliban in Afghanistan.
Somalia-based media affiliated with the homegrown al-Shabab group hailed the Taliban's takeover in Afghanistan in what could be seen as a show of support, says London-based political analyst Ahmed Rajab.
"We are not so sure of the link between the Taliban and al-Shabab, whether these links are opportunistic on the part of al-Shabab or whether they are indeed organic links between the two movements," Rajab told DW.
He says it's still too early to judge, but the Taliban could even read meaning into such messages from Africa's extremists to solidify their influence.
UN Secretary-General Antonio Guterres has warned of an "alarming” expansion of affiliates of the so-called "Islamic State" throughout Africa on the back of the situation in Afghanistan.
That position is shared by Kwesi Aning, the director of the factulty of academic affairs and research at the Kofi Annan Interrnational Peacekeeping Training Centre in Ghana.
The developments in Afghanistan "can potentially put all of us in Africa and the Sahel at risk,” Aning said on Accra-based Citi FM radio.
Huge extremist presence in Africa
Al-Shabab has for many years been fighting to topple Somalia's UN-backed government and impose strict Sharia law in the country. The group has been behind deadly attacks in Somalia and the East Africa region.
Likewise, Nigeria's Boko Haram group has been behind the killing of tens of thousands of people and the displacement of millions in West Africa.
Islamist militants are also active in the Sahel region and parts of the West African sub-region.
In Mozambique Islamist militants have caused havocafter seizing much of the far-north province of Cabo Delgado. More than 2,500 people have been killed and some 700,000 have fled their homes since the insurgency began in 2017, according to the UN.
Islamist extremists also operate in parts of the Democratic Republic of Congo. Political analyst Kwesi Aning stressed the need for measures to guard Africa against any new threats that may arise as a result of the current Afghan crisis.
The executive director of the West Africa Centre for Counter-Extremism (WACCE), Mutaru Mumuni Muqthar, told DW that extremists groups in Africa will only become emboldened by the happenings in Afghanistan.
There is the tendency to "offer not only hope but some sense of legitimacy, a false sense of legitimacy," for groups hoping to topple governments in the regions they operate, he said.
Avoid repeat of the Afghanistan scenario
France has announced that by 2022 it will reduce its military presence in the Sahel region with the process for closure of its bases in northern Mali earmarked to start by the end of 2021.
France, as the former colonial power in the Sahel region, has had troops in Mali since 2013. They aided local forces to oust Islamist extremists who had seized towns in Mali's north.
The Taliban takeover in the wake of the US withdrawal has raised fears that the Sahel region could suffer a similar fate after the French mission ends.
Security analyst and researcher for Signal Risk in South Africa, Ryan Cummings, told DW that France will have to reconsider its decision but said there could be other political considerations since "the French presence in the Sahel has not necessarily lead to either a decrease in operational capacity of extremists groups in this region, nor has it stemmed the degree of violence.”
African governments must be on high alert
The ideology of Boko Haram, al-Shabab and other extremist groups operating in parts of Africa may not be on one level with the Taliban, but for many experts, the Taliban triumph could spur them on. Experts say African governments must pay attention for that reason.
Cummings says African governments need to learn from the Afghan context and provide citzens with a better deal than what the extremists can provide.
"In many of cases, if we go into terrorism-afflicted states across the African continent, we see that these militant groups are actually surrogating the services of the state," he said.
Extremists often provide the judicial and social services that have collapsed in many African countries and then exploit that to win support.
The WACCE executive director, Mutaru Mumuni Muqthar, wants to see African governments focus on "comprehensively dealing with the drivers of terrorism, not just terrorists, because terrorists are killed on the battlefield and terrorism is killed in the local community."
Aning from the Kofi Annan International Peacekeeping Training Centre said what is happening in Afghanistan presents very useful lessons for Africa.
Western countries cannot "just come from somewhere.... superimpose [their] culture, values and army in a country, and think that will work."