Birthday Attack Calculator
Calculate birthday attack parameters, collision probability, time to collision, and attack feasibility for hash functions.
Inputs
Results
Birthday Bound
400,651,869,298,001,200,000,000,000,000,000,000,000
50% Probability Bound
400,651,869,298,001,200,000,000,000,000,000,000,000
Time to Collision
12,695,900,000,000,000,000,000 years
How to Use This Calculator
- Enter the hash function output size in bits.
- Set the number of hashes the attacker can compute per second.
- Review the number of hash computations needed for a 50% collision probability.
- Verify that your hash function output size is at least 2x the desired security level in bits.
- For 128-bit security, use SHA-256 or stronger -- MD5 and SHA-1 are vulnerable.
How the result changes with Hash Length
| Hash Length | Birthday Bound | 50% Probability Bound | Time to Collision |
|---|---|---|---|
| 109 | 29,995,941,092,603,160 | 29,995,941,092,603,160 | 0.95 years |
| 221 | 2,161,435,346,036,399,000,000,000,000,000,000 | 2,161,435,346,036,399,000,000,000,000,000,000 | 68,491,800,000,000,000 years |
| 355 | 318,971,557,281,626,400,000,000,000,000,000,000,000,000,000,000,000,000 | 318,971,557,281,626,400,000,000,000,000,000,000,000,000,000,000,000,000 | 10,107,600,000,000,000,000,000,000,000,000,000,000 years |
| 467 | 22,984,322,984,245,110,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000 | 22,984,322,984,245,110,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000 | 728,329,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000 years |
What each input means
- Hash Length
- Hash output length in bits
- Target Collision Probability
- Desired probability of finding collision
- Hash Operations per Second
- Computational power available
How this is calculated
Formula
Birthday Bound ≈ √(2 × m × ln(1/(1-P)))Worked example, using the default values
- Identify Input ParametersHash Length = 256, Target Collision Probability = 50, Hash Operations per Second = 1000000000 = 3 input(s) provided
- Calculate Birthday BoundBirthday Bound4.006518692980012e+38 = 4.006518692980012e+38
- Calculate 50% Probability Bound50% Probability Bound4.006518692980012e+38 = 4.006518692980012e+38
- Calculate Time to CollisionTime to Collision1.26959e+22 = 1.26959e+22
- Calculate Storage RequiredStorage Required1.1940356174051796e+31 = 1.1940356174051796e+31
- Calculate Estimated CostEstimated Cost4.0065186929800117e+30 = $4,006,518,692,980,011,700,000,000,000,000
Engine last updated . Checked against 1 independently-derived test — how we verify calculators.
Related Calculators
The questions that sit next to this one — chosen by subject, including calculators filed under a different category.
Hash Collision Probability Calculator
Calculate hash collision probability using birthday paradox. Find collision probability and birthday bound for hash functions.
Cryptography & SecurityBrute Force Attack Time Calculator
Calculate brute force attack time, cost, energy consumption, and feasibility for cryptographic systems.
Cryptography & SecurityAttack Probability Calculator
Comprehensive cryptographic attack analysis. Brute force, birthday attacks, side-channel risks, password strength, and key derivation security.
Space TechnologySpace Debris Risk Calculator
Collision probability from object density and orbital altitude.
Technology & ComputingHash Properties Calculator
Compare cryptographic hash function properties. See output size, collision resistance, brute force time, and security status for MD5, SHA-1, SHA-256, SHA-512, and bcrypt.
More in Technology & Computing.