Developer

Password Strength Explained: Entropy, Length and Cracking

Entropy explained with real numbers, why a long plain password beats a short complex one, how attackers crack stolen hashes, and what managers and passkeys change.

Password Strength Explained: Entropy, Length and Cracking
Photo by Kevin Bidwell on Pexels

Key takeaways

  • Entropy is length multiplied by the log of the alphabet size: 16 random characters from 94 symbols give about 105 bits.
  • Each extra character adds more entropy than any symbol rule, so a 20-letter lowercase password beats a 12-character complex one.
  • Attackers crack stolen hash databases offline at billions of guesses per second, which is why slow hashes like bcrypt and Argon2 matter.
  • Reusing one password across sites is the most common way accounts are lost, not brute force.
  • A password manager plus passkeys where offered removes most of the problem.

A strong password is one that an attacker cannot guess in a useful amount of time, even with a stolen copy of the site's database and a rack of graphics cards. In practice that means long (16 characters or more), genuinely random or built from several unrelated words, and used for exactly one account. Length and uniqueness matter far more than the symbols a sign-up form forces you to include.

What entropy means, in plain terms

Entropy is a way of counting how many equally likely passwords yours could have been. It is measured in bits, and every extra bit doubles the number of possibilities. A password with 40 bits of entropy is one of about 1.1 trillion (2^40) candidates. Add one bit and it is one of 2.2 trillion. The attacker has to work through, on average, half of those candidates before landing on the right one.

The formula is short:

entropy (bits) = length × log2(alphabet size)

The alphabet is the set of characters the password can draw from. Lowercase letters alone give 26. Upper and lower case plus digits give 62. All the printable characters on a standard keyboard, including punctuation, give 94 (some generators count 95 by including the space).

Worked example. log2(94) is about 6.55, because 2^6.55 is roughly 94. A 16-character password chosen uniformly at random from those 94 symbols therefore has 16 × 6.55 ≈ 105 bits of entropy. That is 2^105, or roughly 4 × 10^31 possibilities. For comparison, 8 lowercase letters give 8 × 4.70 ≈ 37.6 bits, which is 26^8 = 208,827,064,576 possibilities.

The important caveat: the formula only holds when every character is picked at random. Summer2026! is 11 characters from a 94-symbol alphabet, so the formula says 72 bits. Its real entropy is a small fraction of that, because attackers do not search the whole space. They try dictionary words with a capital first letter and a year and a symbol on the end before they try anything else. Entropy measures the process that produced the password, not the string you end up with. A tool that picks characters with a proper random source, such as the strong password generator, gives you the full figure; a human choosing "random" characters does not.

Length beats complexity

Each additional character multiplies the number of possibilities by the alphabet size. Widening the alphabet from 62 to 94 multiplies by only 1.5 per character, which is worth about 0.6 bits each. One extra character from the full set is worth 6.55 bits. Four extra lowercase letters are worth 18.8 bits. The table shows what that means against an attacker making 100 billion guesses per second, which is a realistic rate for a single modern graphics card against a fast hash such as MD5.

PatternPossibilitiesEntropyTime to search all of it
8 lowercase letters26^8 ≈ 2.1 × 10^1137.6 bitsAbout 2 seconds
8 characters, letters and digits62^8 ≈ 2.2 × 10^1447.6 bitsAbout 36 minutes
8 characters, all 94 symbols94^8 ≈ 6.1 × 10^1552.4 bitsAbout 17 hours
12 lowercase letters26^12 ≈ 9.5 × 10^1656.4 bitsAbout 11 days
12 characters, all 94 symbols94^12 ≈ 4.8 × 10^2378.7 bitsAbout 150,000 years
20 lowercase letters26^20 ≈ 2.0 × 10^2894.0 bitsAbout 6 billion years
16 characters, all 94 symbols94^16 ≈ 3.7 × 10^31105 bitsAbout 12 trillion years

Read the fifth and sixth rows together. Twenty plain lowercase letters, with no capitals, digits or punctuation at all, are far harder to crack than twelve characters drawn from the full keyboard. Rules that demand "at least one uppercase, one digit and one symbol" exist because an eight-character limit made them necessary in the 1990s. They now mostly produce predictable patterns: capital at the start, digit and exclamation mark at the end. Cracking software has rule sets written specifically to model those habits, which is why current NIST digital identity guidance tells sites to stop enforcing composition rules and to allow long passwords instead.

If a site insists on a symbol and a digit, put them somewhere other than the end, and keep the password long anyway. The symbol satisfies the form; the length is what protects you.

A padlock on a keyboard representing password security
Photo by Pixabay on Pexels

Passphrases: long and still memorable

A passphrase is several unrelated words joined together, and it is the easiest way for a human to carry a lot of entropy around. The maths works per word rather than per character. The Diceware word list has 7,776 entries, so each word chosen at random from it contributes log2(7776) ≈ 12.9 bits.

  • Four random words: 51.7 bits. Fine for a low-value account, weak as a master password.
  • Six random words: 77.5 bits. A sensible master passphrase for a password manager or disk encryption.
  • Eight random words: 103.4 bits. Equivalent to the 16-character random password above, and far easier to type from memory.

Something like copper-velvet-trombone-island-pastry-nine is 41 characters long, yet most people can hold it in their head after a dozen typings. Two rules keep the maths honest. First, let a random source pick the words. When people choose their own, they pick related words or a famous quotation, and attackers keep lists of those. Second, do not count on capitals or substitutions to add much. Changing island to Isl4nd adds perhaps two or three bits and makes the phrase harder to remember.

The one practical problem is that some older systems cap passwords at 16, 20 or 32 characters, and a few still silently truncate. Check the limit before relying on a long phrase.

Why reuse is the real risk

Most accounts are not lost to brute force. They are lost because the same email address and password were used on a forum that was breached in 2019, and the pair has been on sale ever since. Attackers feed those lists into automated tools that try each pair against banks, shops and email providers. This is called credential stuffing, and it works because the password is often correct.

A 105-bit password reused across forty sites is only as safe as the worst of the forty. If one of them stored it in plain text, or hashed it with MD5 and no salt, the strength you worked so hard for is irrelevant: the attacker simply reads it. Uniqueness, therefore, is not a nice-to-have. It is the single property that stops one breach becoming forty.

Nobody can memorise forty unique random passwords, which is the honest reason to use a manager. For throwaway accounts, a distinct login name helps as well. A unique name from the random username generator makes it harder for someone to link your forum account to your email or your other profiles, and it keeps a leaked username from being an automatic match elsewhere.

Email and vault master passwords are special. Your email account can reset every other password you own, so it deserves the strongest passphrase you have, plus two-factor authentication.

A person logging in on a laptop at home
Photo by cottonbro studio on Pexels

What hashing is, and why MD5 is dead

A well-run site never stores your password. It stores a hash, which is a fixed-length fingerprint produced by a one-way function. Put the same text in and you always get the same output; change one letter and the output changes completely; and there is no practical way to run the function backwards.

The MD5 hash of password is 5f4dcc3b5aa765d61d8327deb882cf99. The SHA-256 hash of the same word is 5e884898da28047151d0e56f8dc6292773603d0d6aabbdd62a11ef721d1542d8. Paste password and then Password into the hash generator and compare the outputs: a single capital letter changes every character of the result.

At login the site hashes what you typed and compares it with the stored fingerprint. If the database leaks, the attacker gets fingerprints rather than passwords. Whether that protects you depends on which function was used and how.

MD5 dates from 1992 and has two separate problems. The first is that researchers found collisions in 2004, meaning two different inputs that produce the same hash, and by 2008 that weakness was used to forge a trusted certificate. The second problem is the one that matters for passwords: it is fast. Fast is exactly what you do not want, because an attacker testing guesses benefits from speed as much as the server does. SHA-1 and SHA-256 are also fast. SHA-256 is still perfectly sound for checksums and digital signatures, but for password storage it is in the same boat as MD5.

Two further ideas make a password hash useful:

  • Salt. A random value stored alongside each hash and mixed in before hashing. Two users with the same password then get different hashes, and precomputed lookup tables (rainbow tables) become useless because every salt would need its own table.
  • A work factor. Purpose-built password hashes such as bcrypt, scrypt and Argon2id are deliberately slow and tunable. A site can set them to take a tenth of a second per login, which users never notice, while slowing an attacker by the same factor on every single guess.

How hashes are cracked offline

Online guessing, where someone hammers the login form, is a solved problem: a few failed attempts trigger a lockout or a delay. Offline cracking is different. The attacker already has the hash database, so nothing can rate-limit them. They run guesses on their own hardware and only need to find a match.

A typical sequence looks like this:

  1. Wordlists. Every password seen in previous breaches, hundreds of millions of them, tried as-is.
  2. Rules. Each wordlist entry transformed in the ways people actually behave: capitalise the first letter, append 1 through 2026, swap a for @, add an exclamation mark. One word becomes thousands of candidates.
  3. Masks. Patterns such as "one capital, five lowercase, two digits" tried exhaustively. This is what catches Robert87.
  4. Combinations. Two or three dictionary words joined, with and without separators, which is why self-chosen passphrases made of related words fall quickly.
  5. Brute force. Everything else, which is where the entropy table finally applies.

Speed is what makes this work. At the time of writing, one high-end consumer graphics card tests well over 100 billion MD5 hashes per second, around 20 billion SHA-256 hashes, and only a few thousand bcrypt hashes at a sensible cost factor. Run the eight-character, 94-symbol example through those numbers: the whole space takes about 17 hours under MD5, roughly four days under SHA-256, and tens of thousands of years under bcrypt. Same password, same hardware, wildly different outcomes, decided entirely by the site's choice of hash.

You cannot control which hash a site uses. You can control two things: whether your password is in a wordlist (not if it is random), and whether cracking it on one site unlocks anything else (not if it is unique).

Password managers and passkeys

A password manager is a vault that generates a long random password for every account, stores it encrypted, and fills it in for you. The practical upshot is that the strength and uniqueness problems both vanish, and you are left with one passphrase to remember: the master. Make that a six-word random phrase or better, turn on two-factor authentication for the vault, and keep the recovery codes somewhere physical.

Passkeys go a step further by removing the shared secret altogether. When you register a passkey, your device creates a pair of keys. The private key stays on the device (or in your platform's encrypted sync), and the site stores only the public key. At login the site sends a challenge, your device signs it after you unlock it with a fingerprint, face or PIN, and the site verifies the signature. Nothing reusable is ever sent, so there is nothing for a breach to leak and nothing for a phishing page to capture, because the passkey is bound to the real site's domain and will not respond to a look-alike.

MethodWhat a breach leaksPhishing resistantNeeds you to remember
Reused passwordThe password, usable everywhereNoOne password
Unique random passwords in a managerOne hash, useful for one site onlyPartly (the manager will not autofill on a wrong domain)One master passphrase
PasskeyA public key, useless on its ownYesYour device unlock

Passkeys are not yet universal, and account recovery still matters if you lose every device, so the realistic position in 2026 is a manager holding unique passwords, with passkeys switched on wherever a site offers them.

Where to go next

Generate something genuinely random with the strong password generator, choosing 16 characters or more, or a passphrase of six words. Use the hash generator to see for yourself how MD5, SHA-1 and SHA-256 fingerprints differ, and why a one-letter change produces an unrelated result. Both run in your browser and nothing you type is sent anywhere.

Frequently asked questions

How long should a password be in 2026?

Aim for at least 16 characters if it is random, or at least five or six random words if it is a passphrase. Sixteen random characters from the full keyboard give about 105 bits of entropy, which is out of reach for offline cracking even against a fast hash. The limit on the other side is the site: a few still cap passwords at 20 or 32 characters, so check before choosing a very long phrase.

Is a 12-character password strong enough?

Twelve genuinely random characters from the full keyboard give about 79 bits, which would take a single graphics card well over a hundred thousand years to exhaust against MD5. That is strong enough for most accounts. The qualifier is random: a 12-character password made from a word, a year and a symbol is in every cracking rule set and can fall in seconds regardless of its length.

Does changing passwords regularly make them stronger?

No. Forced rotation tends to produce weaker passwords, because people make the smallest change that passes the rule, such as incrementing a number at the end. Current guidance from NIST and the UK NCSC is to change a password only when there is a reason to, such as a breach or suspected compromise, and to invest instead in length, uniqueness and two-factor authentication.

Are password managers safe to use?

For almost everyone, a manager is far safer than the alternative, which is reusing a handful of memorable passwords. The vault is encrypted with your master passphrase, so even the provider cannot read it, and the manager generates a unique random password for every site. The risks to manage are a weak master passphrase and no two-factor authentication on the vault, both of which are in your control.

What is a passkey and does it replace passwords?

A passkey is a pair of cryptographic keys created by your device for one website. The site stores the public key; the private key never leaves your device and is unlocked by a fingerprint, face or PIN. There is nothing to type, nothing reusable to leak in a breach, and the passkey refuses to work on a look-alike phishing site. It replaces the password on sites that support it, which is a growing but not yet complete list.

Is MD5 still safe for anything?

MD5 is fine as a quick checksum to detect accidental corruption, such as confirming a download finished intact, because that only needs the hash to change when the data changes. It is not safe for anything an attacker might tamper with, since collisions can be manufactured, and it is unsuitable for storing passwords because it is extremely fast to compute. Use SHA-256 for integrity and bcrypt or Argon2id for passwords.

Try the tools from this guide

Keep reading

Related guides

All guides