A wave of young politicians and activists are challenging ageing leaders across much of Africa, reflecting seismic shifts on the continent that are poised to dramatically change the lives of hundreds of millions of people.

The new generation of politicians are in their mid-30s and can barely remember the cold war or the conflicts that brought many autocrats or ruling parties to power. Often educated and urban, they are at the intersection of massive changes that experts say may dramatically strengthen democracy in Africa in decades to come.

William Gumede, an analyst in Johannesburg, South Africa, said: “It is something to be wildly optimistic about … The big question is: how do we harness this, how do we support these younger leaders?”

Emmerson Mnangagwa, president of Zimbabwe; Cyril Ramaphosa, president of South Africa; Yoweri Museveni, president of Uganda Composite: Getty / Barcroft

The new generation faces significant resistance from incumbent rulers, who are sometimes more than twice their age and are backed by political organisations in power for decades, well-armed militaries, brutal security services and entrenched systems of patronage that have captured massive resources.

On Thursday, Bobi Wine, a 36-year-old former reggae star and opposition member of parliament, returned to Uganda to a rapturous welcome from thousands of supporters in Kampala, the capital.

Wine, whose real name is Robert Kyagulanyi Ssentamu, had been in the US where was receiving medical treatment for injuries sustained in detention in August. He has pledged to force the Ugandan president, Yoweri Museveni, 74, out of power. Museveni has been in power since 1986, when Wine was four years old.

Earlier this week, Wine told the Guardian he wanted to prove that the “power of the people is greater than the people in power. There are 40 million people who need hope, so I will go and meet them, no matter what,” he said.

In Rwanda, the autocratic rule of 60-year-old Paul Kagame was challenged last year by Diane Rwigara, a 38-year-old accountant. She is now in jail.

Diane Rwigara, a prominent critic of Rwanda’s President Paul Kagame. Photograph: Cyril Ndegeya/AFP/Getty Images

In Zimbabwe, the new president is Emmerson Mnangagwa, 76, who took power after a military takeover forced out Robert Mugabe, 94, last year. Mnangagwa narrowly beat Nelson Chamisa, the 41-year-old leader of the Movement for Democratic Change, in a contested election in July.

During the campaign, Chamisa told the Guardian that he was the voice of Zimbabwe’s youth and it was time for the old leaders of the country to step aside.

Last week, officials from Zimbabwe’s ruling Zanu-PF party suggested raising the presidential age limit – which currently stands at 40 – to block “immature people” from the office.

“African societies remain very patriarchal … but the citizen base is young and so there is a clash happening of politics, culture and tradition,” said Gumede, director of Democracy Works, a thinktank working across the region to prepare young people to be eventual presidential candidates.

The median age in Zimbabwe is around 20, slightly higher than for the continent. In Uganda, 70% of the population under 24. Abiy Ahmed, the 41-year-old former soldier and technocrat who is now prime minister of Ethiopia, is an exception. The average age of African leaders is 62, which means that the continent with the youngest citizens has the oldest rulers.

The Movement for Democratic Change leader Nelson Chamisa in Harare, Zimbabwe. Photograph: Mike Hutchings/Reuters

These include Paul Biya, 85, has been in power in Cameroon for 35 years, Teodoro Obiang, 75, who has ruled Equatorial Guinea since 1979, and 81-year-old Abdelaziz Bouteflika who, although confined to a wheelchair since a strike five years ago, may seek a fifth term as president of Algeria next year.

South Africa, the most industrialised country in Africa, will also go to the polls next year with President Cyril Ramaphosa, 65, hoping to win a new mandate for the African National Congress, which has been in power since 1994.

More than 10 million eligible voters – about a quarter of the electorate – will be under 30 and thus too young to remember the ANC leadership’s struggle against the repressive white supremacist apartheid regime that collapsed in the early 1990s. Analysts say this will fundamentally change politics in the country.

The two main opposition parties, the centre-right Democratic Alliance and the far-left Economic Freedom Fighters, are led by Mmusi Maimane, 38, and Julius Malema, 37, respectively.

“Both are capable of harnessing the disaffection of the enormously powerful but largely untapped youth vote,” the local Mail and Guardian newspaper commented.

Mmusi Maimane (right), at a rally with thousands of people in Soweto, South Africa, July 2016. Photograph: Kevin Sutherland/EPA

Nic Cheeseman, a professor of democracy at the University of Birmingham, cautioned that many young politicians end up among the ranks of the parties and regimes they once fought against.

“We always get excited about the youth because we see a new cohort and we know how young African countries are and how young they are going to be … but research shows that young revolutionaries often end up as minister for something. They get co-opted,” Cheeseman said.

In the Democratic Republic of Congo, where almost two-thirds of the country are under 25, civil society organisations such as Lucha are campaigning for radical reform of a sclerotic political system.

“The old guard need fresh blood, so they co-opt the youngsters. So the challenge is to define yourself and not just be opportunistic. How do you maintain the moral high ground?” said Sylvain Saluseke, a veteran member of Lucha.

Young leaders are far from immune from the temptations of illegal material gain or populism. Chamisa has repeatedly been accused of making unrealistic promises to win votes. Bobi Wine has been repeatedly accused of homophobia.

Julius Malema in Johannesburg, South Africa. Photograph: Gianluigi Guercia/AFP/Getty Images

Many longstanding rulers and parties still command massive support in rural areas where government control is greater, though more than half the population of Africa is predicated to live in towns and cities within 30 years.

Youth alone is not enough to effect radical change, said Cheeseman. “The really important element is urbanisation. The biggest divide is between urban and rural, not young and old. When the majority of national votes are urban … that will massively transform opposition parties and politics.”