xkcd and diceware passphrase generator
Random words from the EFF word list, picked in your browser. Choose how many, and see exactly how much entropy you get.
— —
Pick at least one character type.
Options changed — generate again to apply.
Loading the word list…
The xkcd four
In 2011, xkcd comic 936 made a simple arithmetic case: four random words are both harder to guess and easier to remember than a short password stuffed with substitutions. The four words in the comic itself, correct horse battery staple, are now in every cracking dictionary, which is the whole point of generating your own.
51.7 bits, the xkcd number. The default here is six, at 77.5.
How diceware works
Arnold Reinhold published diceware in 1995. Roll five dice, read the result as a five-digit number, find that number in a numbered word list, and write down the word. Repeat for every word you want. The list this page uses starts at 11111, which is the word abacus.
This page rolls with your browser's cryptographic random number generator rather than dice, which is the same idea at a thousand times the speed. If you would rather trust your own hands, the word list is a plain text file you can download and print.
What each word is worth
The list holds 7,776 words, so every word you add multiplies the number of possible passphrases by 7,776, which is 12.9 bits of entropy. Each bit doubles the guesses an attacker needs.
| Words | Entropy | Roughly the same as |
|---|---|---|
| 3 | 38.8 bits | 6 random characters — too short on its own |
| 4 | 51.7 bits | 8 random characters — the xkcd four |
| 5 | 64.6 bits | 10 random characters |
| 6 | 77.5 bits | 12 random characters — the default here |
| 7 | 90.5 bits | 14 random characters |
| 8 | 103.4 bits | 16 random characters |
| 9 | 116.3 bits | 18 random characters |
| 10 | 129.2 bits | 20 random characters — the maximum here |
The words come from the EFF long word list, 7,776 words chosen to be easy to type, easy to say and hard to confuse with each other. It is served from this site, licensed CC BY 3.0, and never fetched from anywhere else.
Questions
What is the xkcd password method?
Comic 936, published in 2011, worked out that four random common words give an attacker far more to guess than a short password with letters swapped for symbols, and that people can actually remember the words. This page is that method with the arithmetic shown. Do not use the comic’s own four words: they are famous, so every cracking tool tries them first.
What is diceware?
A method Arnold Reinhold published in 1995. You roll five dice, read the digits as a five-figure number, look that number up in a numbered list of words, and write the word down. Each roll picks one word out of 7,776. It is the same idea as the xkcd four, with a published list and randomness you can watch happen on the table.
How many words does a passphrase need?
Four words is 51.7 bits, which is fine where an attacker only gets a few tries before being locked out. Six words is 77.5 bits and is the sensible floor for anything that protects other things: a password manager’s master password, disk encryption, a backup. Beyond eight words you are past what any realistic attacker can reach.
Is a passphrase stronger than a password?
Strength is the number of guesses an attacker needs, not how scrambled the result looks. Six random words is about 77 bits, roughly the same as twelve random characters from a full keyboard, and far easier to type from memory. The catch is the word “random”: a phrase you thought up yourself is worth a fraction of what the arithmetic here assumes.
Can I use real dice instead?
Yes, and it is the original method. Roll five dice, read them as a five-digit number, find that row in the list, write the word down, and repeat until you have enough words. The word list is a plain text file on this site that you can download and print. Dice cost you a few minutes and remove any question about where the randomness came from.
Should I add numbers, capitals or symbols?
They add less than you would expect. Capitalising every word is a pattern an attacker assumes anyway, and two digits on the end are worth about 6.6 bits. One more word is worth 12.9. Add them when a site insists on a digit or a symbol, and otherwise spend the effort on another word.
Where should I use a passphrase rather than a password?
Anywhere you type it yourself: the master password for your password manager, disk encryption, Wi-Fi, a router, a recovery phrase, the login you need before the manager is available. For the hundreds of accounts a manager fills in for you, random characters are the better choice, because nobody ever has to read or remember them.