Random Country Generator
Draws from the 193 UN member states unless you widen the scope, shows the capital and ISO code with every result, and marks the countries whose capital has more than one defensible answer.
Which list this draws from, and why that is the first question
"Random country" sounds like a settled category and is not one. The 193 UN member states are the closest thing to an agreed list, so that is the default here and the scope control says so in words rather than leaving you to reverse-engineer it from the results.
Widen the scope one step and you add the two permanent observer states, the Holy See and the State of Palestine. Widen it again and you add a selection of territories and partially recognised states — Taiwan, Kosovo, Greenland, Puerto Rico, Hong Kong and others — each labelled as such on its card. Nothing is quietly folded in.
Other counts are not wrong, they answer a different question. The International Olympic Committee recognises 206 national committees; FIFA has 211 member associations; ISO 3166-1 issues codes to around 250 entities, most of the surplus being dependencies.
The capitals that make unfair questions
A capital-city question assumes one right answer. For most countries that holds. For a couple of dozen it does not, and those are exactly the ones a generator will hand you at the worst moment. Each is marked here with a flag symbol and a note.
- Two capitals with split functions. Bolivia is constitutionally capitalled at Sucre while the government sits in La Paz. Benin, Côte d'Ivoire, Tanzania and Sri Lanka all separate the official capital from the working one.
- Three capitals. South Africa divides the executive, legislative and judicial seats between Pretoria, Cape Town and Bloemfontein.
- Constitutional capital, other seat of government. The Netherlands names Amsterdam in its constitution while government sits in The Hague. Switzerland designates no capital at all in its constitution; Bern is the federal city and does the job.
- Recently moved, or moving. Burundi made Gitega its political capital in 2019. Kazakhstan's capital has been renamed twice in a decade and is Astana again. Indonesia has legislated for a new capital, Nusantara, while Jakarta still holds the role.
- Contested or disrupted. Jerusalem, Sana'a and Tripoli all come with qualifications that a one-line answer cannot carry honestly.
Tick the quiz-safe box and every one of them leaves the pool. Quiz-sheet mode applies that filter automatically, because an unmarkable question helps nobody.
Classroom and game uses that actually work
- Capital-city sheets. Quiz-sheet mode prints numbered questions with the answer key underneath, ready to copy into a document or download as text.
- Continent sorting. Tick two continents, draw twelve, and have the class sort them before the cards are revealed.
- Research-a-country lots. One draw per pupil, with the ISO code as a search handle that avoids the Georgia and Congo ambiguities.
- Map work. Draw one, find it on the wall map, name a neighbour.
How the data and the draw work
Every country, capital, ISO 3166-1 alpha-2 code and continent is written into this page's source. Nothing is fetched, and your filter choices never leave the device — though the ad slot on this page will load third-party resources on its own account once advertising is enabled, as it would on any ad-supported site.
Continents follow the UN Statistics Division geoscheme, with the Americas split into North America — which there includes Central America and the Caribbean — and South America. That convention puts Russia in Europe and Turkey, Cyprus, Georgia, Armenia, Azerbaijan and Kazakhstan in Asia, even though several of those countries straddle the boundary. Egypt sits in Africa despite the Sinai. Reasonable atlases differ.
A draw shuffles the matching countries and takes the first few, so one draw never
repeats a country, though consecutive draws are independent and can. Numbers come from
crypto.getRandomValues with rejection sampling, so no country is slightly
favoured by the arithmetic.
Bad input is corrected rather than obeyed: a count above thirty or below one is clamped, a blank or non-numeric count falls back to six, a request larger than the matching pool draws the whole pool and says so, and unticking every continent produces a message rather than an empty box.
Frequently asked questions
How many countries are there in the world?
There is no one number, only a choice of list. 193 states are UN members; two more — the Holy See and the State of Palestine — are permanent observers. Each of the other bodies above is answering its own question. This page starts from the UN membership because it is the list most commonly meant.
Why does Taiwan or Kosovo not appear in the draw?
Because the default pool is UN member states, and neither is one. Choose the third scope option and they appear with a status label and a note explaining the position. The territory list is a selection of well known cases rather than a complete catalogue — there are dozens of dependencies not listed here.
Which capital does it give when a country has more than one?
All of them, with the role of each spelled out. That is more useful than a single confident answer, and it is the honest form of the fact. If you want the ambiguous cases gone entirely, the quiz-safe checkbox removes them.
Can I turn a draw into a printable quiz?
Yes. Switch the output to quiz sheet: you get numbered capital-city questions and a separate answer key, which Copy and Download both preserve. Downloads are plain text in quiz mode and CSV in card mode, so a card draw opens straight into a spreadsheet.
Limits worth knowing
There are no population, area or currency figures here on purpose. Those change, sources disagree, and a stale number stated confidently is worse than no number. What is included is stable: names, capitals, codes and continents, with the moving parts flagged rather than smoothed over.
Country names change — Eswatini in 2018, North Macedonia in 2019, Türkiye at the UN in 2022 — and older textbooks will disagree with these cards. Where a familiar former name exists it is shown as an alias. Sovereignty disputes are noted, never adjudicated: the tool records that a claim exists, and takes no position on it.