Vol. I a living index of named laws · est. mmxxvi no ads · no account
The Law Tomeindex of named laws

The Infinite Monkey Theorem

also known as — The monkeys and typewriters
"A monkey typing at random for infinite time will almost surely type all of Shakespeare."
In plain English

What does The Infinite Monkey Theorem mean?

The infinite monkey theorem states that a monkey striking keys at random for an infinite amount of time will almost surely type any given text, such as the complete works of Shakespeare. More formally, in an unending sequence of independent random characters, any fixed finite string appears with probability one, and indeed infinitely often. The vivid image dramatises a precise fact about randomness and infinity, and it is routinely misunderstood.

Reliability

Rated Empirical: grounded in studies or measurable evidence. The other 608.

Lineage
1913COINED
How it works

How does The Infinite Monkey Theorem work?

For any target string, a single random block of the right length matches with a tiny but positive probability. Over many independent attempts, the chance of never matching falls toward zero, so across infinitely many attempts a match is certain. Because the per-trial probability stays fixed and the trials are independent and endless, the string not only appears but recurs endlessly, a consequence of the Borel-Cantelli reasoning. The phrase almost surely means probability one in this infinite limit, not a guarantee within any finite stretch of typing.

Figure illustrating The Infinite Monkey Theorem
The Infinite Monkey Theorem — New York Zoological Society · Public domain · source
Where you'll see it

What are examples of The Infinite Monkey Theorem?

The banana block On a fifty-key keyboard, a six-letter word matches with probability one in fifteen billion per block; minuscule, yet the chance of never matching over infinitely many blocks is zero.
The Hamlet number For the full text of Hamlet the odds on a single pass are astronomically small, so remote that in any operational sense the event has probability zero within the universe's lifetime.
The real monkeys A 2002 experiment with macaques and a keyboard produced a few pages dominated by the letter S, with the animals treating the keyboard as anything but a random generator.
Types & variants

What are the types of The Infinite Monkey Theorem?

The finite reality§

A 2024 analysis found that within the universe's lifespan even a vast troop of typing chimpanzees could almost certainly never produce Shakespeare's works, so the popular version misleads about real time.

Borel's original point§

Émile Borel used the image in 1913 to illustrate statistical mechanics, that some outcomes, while not strictly impossible, are so improbable they can be treated as never happening.

Why it matters

Why does The Infinite Monkey Theorem matter?

It is a memorable teaching example for almost-sure events and the gulf between what is possible and what is probable: an outcome can be guaranteed in the infinite limit yet effectively impossible in any physical timeframe. It clarifies why arguments that invoke infinite time must be handled carefully, and it is a favourite illustration of randomness, independence, and the meaning of probability one.

Working with it

How do you apply The Infinite Monkey Theorem?

  • Read almost surely precisely — take probability one as a statement about the infinite limit, not a promise of occurrence in any finite run.
  • Separate possible from probable — distinguish an event with positive probability, certain over infinite trials, from one likely to occur in a realistic time, which this is not.
  • Distrust the popular version — remember that in any physical timeframe the target essentially never appears, so the image dramatises infinity, not achievable typing.
Where it breaks down

What are the limits of The Infinite Monkey Theorem?

The theorem is a rigorous probability result, a consequence of independence and the Borel-Cantelli reasoning, but its content is a limit statement about infinity. It says nothing about finite or realistic timeframes, in which the expected time to produce even a short passage vastly exceeds the age and projected lifespan of the universe. It assumes truly independent, uniform random keystrokes, which real monkeys and many software imitations do not provide. Its reliability is high as mathematics and its reputation as a source of confusion is equally high.

What it doesn't say

What are common misconceptions about The Infinite Monkey Theorem?

It would not happen in any reasonable timeframe; the expected waiting time dwarfs the lifetime of the cosmos, so probability one here never means soon. Probability one does not mean guaranteed within finite time; it is an asymptotic property that permits the event to be absent from every physically possible run. And software monkeys that use matching shortcuts are not demonstrations of the theorem, which requires genuinely independent random typing.

Is it real?

Is The Infinite Monkey Theorem real?

Yes, as far as the evidence goes. The Infinite Monkey Theorem is rated Empirical here: it rests on studies or measurements rather than on a saying.

Rated from three sources. 609 of the 1,116 entries carry this rating. How the scale works.

Seldom printedin printed books: one of 194 names in its band, of 903 measured
35 of 49entries in statistics & probability carry the same rating

The best-known laws are the least likely to rest on measurement.

Origin

Where did The Infinite Monkey Theorem come from?

The modern typing-monkeys image is due to the mathematician Émile Borel in 1913, popularised by Arthur Eddington in 1928, with conceptual antecedents in Aristotle and Cicero on atoms and letters.

How the name spread

When did people start saying “The Infinite Monkey Theorem”?

1800coined 19132019
How often “Infinite Monkey Theorem” appears in printed English, which takes hold around 2003 and peaks around 2019. The idea dates to 1913: the phrase took about 90 years to reach print in any quantity, which is the gap this chart measures. Source: Google Books Ngrams.
Known elsewhere as

What is The Infinite Monkey Theorem called in other languages?

  • Arabicمبرهنة القرد اللامنتهية
  • GermanInfinite-Monkey-Theorem
  • Spanishteorema de los infinitos monos
  • Frenchparadoxe du singe savant
  • Hindiअनंत बंदर प्रमेय
  • Italianteorema della scimmia instancabile
  • Japanese無限の猿定理
  • Portugueseteorema do macaco infinito
  • Russianтеорема о бесконечных обезьянах
  • Chinese無限猴子定理

10 languages, as recorded on Wikidata. These are names the idea already goes by, not translations we made. The whole index by language.

What we checked

  • 1,116entries in the tomeListed one by one on the browse page.
  • 1,116of them citing a sourceOpen any entry: its sources sit at the foot of the page.
  • 2,489source references in allEach is named, and linked wherever the source is online.