Random Africa Country Generator

Press generate to get one to ten African countries at random, each shown with its flag and two-letter ISO code.

Type a number from 1 to 10, press the button, and you get that many African countries picked at random, each with its flag and two-letter ISO code. The pool is the 54 sovereign states of Africa plus two territories that sit on the continent, Western Sahara and Mayotte, so 56 entries in all. It is the same country list that powers our Random Flag Generator, filtered down to one continent.

What you can set

There is one control: how many countries you want, from one to ten. Each press reshuffles the whole African list and takes the first N entries, so a single result never contains the same country twice. Ask for ten and you get ten different nations; press again and you get a fresh draw. There are no region filters (North, West, East, Central, Southern) and no way to exclude countries you have already seen, so if you are working through the continent one country at a time, keep your own checklist.

What each result shows

Every country comes as a card with a flag image and the name followed by its ISO 3166-1 alpha-2 code in brackets, for example "Ghana (GH)" or "Madagascar (MG)". Flags are SVG files, so they stay crisp on any screen. The two-letter code is handy if you are feeding the result into a spreadsheet, a quiz app or a country-flag emoji lookup. The card does not show the capital, population or a map. If you want a capital to go with the country, the Random Capital City Generator covers that separately.

Ways people use it

  • Geography practice. Draw five countries and try to place each on a blank map of Africa before checking. The flag on the card doubles as a second thing to memorize.
  • Classroom assignments. Teachers use it to hand out research topics fairly. Each student presses once and writes about the country they get, which avoids twenty reports on Egypt.
  • Trivia and pub quiz rounds. Pull ten countries and build a round around them: name the capital, guess the population, identify the flag with the name hidden.
  • Cooking, reading and film challenges. Some people pick a random African country each month and cook a dish, read a novel or watch a film from it. The generator removes the bias toward the handful of countries everyone already knows.
  • Worldbuilding and travel daydreaming. A random pick is a quick way to start reading about somewhere you would never have chosen on purpose, like Comoros or Eswatini.

What counts as an African country here

The African Union has 55 member states, and the United Nations recognizes 54 sovereign African countries. The difference is Western Sahara, which the AU admits as the Sahrawi Arab Democratic Republic but which Morocco administers most of. We include Western Sahara as its own entry with its own flag. We also include Mayotte, an island between Madagascar and Mozambique that is a department of France but is geographically African. Réunion, St. Helena and the Canary Islands are not tagged as African in the list, so they will not come up.

A few names follow the ISO short form rather than the long official one. The two Congos appear as "Congo - Kinshasa" (CD, the Democratic Republic of the Congo) and "Congo - Brazzaville" (CG, the Republic of the Congo), Ivory Coast appears as Côte d'Ivoire (CI), and Swaziland appears under its current name, Eswatini (SZ). Cabo Verde is listed as Cape Verde (CV).

By region, the pool breaks down roughly like this: six countries in North Africa (Algeria, Egypt, Libya, Morocco, Sudan, Tunisia) plus Western Sahara; sixteen in West Africa from Mauritania down to Nigeria; nine in Central Africa including both Congos, Cameroon and Chad; around fourteen in East Africa and the Horn including Ethiopia, Kenya, Tanzania and the island states of Madagascar, Mauritius, Seychelles and Comoros; and the rest in Southern Africa, from Angola and Zambia down to South Africa and Lesotho. Because every entry has the same chance, small island nations like Seychelles (population about 100,000) come up exactly as often as Nigeria (over 220 million).

If you want a country from somewhere else, the Random Asian Country Generator and Random European Country Generator work the same way, and the Random Country Generator draws from the whole world. Browse all country, city and place generators for cities, states and more.

Frequently asked questions

How many African countries can the generator pick at once?

Between one and ten per press. Each press shuffles the full list of 56 entries and takes the first few, so a single result never repeats a country. Press again for a completely new draw.

Does the list include all 54 African countries?

Yes. All 54 UN-recognized sovereign states are in the pool, plus Western Sahara and the French department of Mayotte, for 56 entries in total. Each has its own SVG flag and ISO code.

Can I get just one random country in Africa?

Enter 1 in the number box (it is the default) and press the button. You get a single country card with its flag and code, and pressing again gives you a different random pick.

Why is Ivory Coast shown as Côte d'Ivoire?

The list uses the ISO short names, which follow each country's own preferred spelling. That is also why you see Eswatini rather than Swaziland and Cape Verde for Cabo Verde.

Does it show the capital or a map?

No. The card shows the flag, the country name and the ISO code only. For capitals use the Random Capital City Generator, and for a random city anywhere in the world try the Random City Generator.