ProtemKey

Crack-time calculator

What do bits mean in practice? Describe a randomly generated secret, pick an attack rate, and see the average time to guess it. Or work backwards from the time you want to the length you need.

The secret
78.7 bitsVery strong

94¹² ≈ 4.8 × 10²³ possibilities.

Online, rate-limitedabout 1017 years100 guesses per hour
Offline, slow hash757 billion years10,000 guesses per second
Offline, fast hash76 thousand years100 billion guesses per second

Average time to guess (half of all possibilities). The rates are illustrative assumptions, not measurements.

Your rate–

Work backwards

The formula

A secret chosen uniformly at random from S possibilities has log2(S) bits of entropy. An attacker who tries them in some order finds it, on average, halfway through: after S/2 guesses. At r guesses per second that takes S/(2r) seconds. For random characters, S = NL (set size to the power of the length); for random words, S = Wk (list size to the power of the word count).

This only holds for secrets that really were chosen at random. A password a person made up has far fewer likely possibilities than its length suggests, because attackers try likely choices first. For those, use the strength checker, which estimates instead.

The rates are assumptions

Illustrative attack rates used throughout this site. They are order-of-magnitude assumptions, not measurements; real rates vary with hardware, hash settings and defenses.
ScenarioRate (assumed)Situation
Online, rate-limited100 guesses per houra login form that slows down or locks out repeated failures
Offline, slow hash10,000 guesses per seconda stolen database hashed with a deliberately slow, salted scheme (bcrypt class)
Offline, fast hash100 billion guesses per seconda stolen database hashed with a fast unsalted hash (MD5, SHA-1 or NTLM class) on a high-end GPU rig

Real rates depend on the attacker's hardware, how the service stored the password and whether it limits attempts. The three above are rough reference points spanning that range, from a login form that locks after repeated failures to a GPU rig working on a leaked, poorly hashed database. How long it takes to crack a password explains where they come from and why the spread is so wide.

Common cases

Average time to guess (half of all possibilities) for secrets chosen uniformly at random. Rates are illustrative assumptions; human-chosen passwords fall far faster than their length suggests.
SecretBitsOnline, 100/hourSlow hash, 104/sFast hash, 1011/s
4-digit PIN13.32.1 daysless than a secondless than a second
6-digit PIN19.9208 days50 secondsless than a second
8 random lowercase letters37.6119 thousand years121 days1 second
8 random printable characters52.43.5 billion years9.7 thousand years8.5 hours
12 random letters and digits71.5about 1015 years5.1 billion years511 years
3 random EFF words38.8268 thousand years272 days2.4 seconds
4 random EFF words51.72.1 billion years5.8 thousand years5.1 hours
5 random EFF words64.616 trillion years45 million years4.5 years
6 random EFF words77.5about 1017 years350 billion years35 thousand years
7 random EFF words90.5about 1020 yearsabout 1015 years272 million years
16 random printable characters104.9about 1025 yearsabout 1019 years5.9 trillion years
20 random printable characters131.1about 1033 yearsabout 1027 yearsabout 1020 years