I am running a test to see if I can obtain a successful bitcoin address collision after generating billions of addresses. I am not entirely sure how I would check them yet. Basically I have an extra 10TB hard drive and am running supervanitygen on my 32-core, 128gb ram linux work computer. It seems to be generating about 90,000,000 (90 million) addresses (address + private key pair) every 4 hours.

Do you think it's possible or likely to run into an address collision this way? Or perhaps if everyone in the world did the same thing? Or what if I waited 10-20 years, and then checked the addresses?

This is all just a test to see if the bitcoin system is secure enough for big investment decision.


Because of the Birthday paradox, you only need 280 addresses (despite there existing 2160 different address combinations) before a collision becomes probable.

Thankfully, that is still an enormous number. At 90 million addresses per 4 hours, it will take about 445 times the age of the universe to reach that number.

It's also irrelevant. Even if anyone - or everyone - generates 90 million addresses per 4 hours, there aren't that many addresses receiving funds. Thus only actually used addresses matter.

  • 9
    Also, in that case the collision would almost certainly be between two addresses you yourself generated... which isn't usually very useful for an attacker. – G. Maxwell Jan 19 at 20:36
  • 1
    I'm confused at how you arrived at 2^80 for the birthday paradox. That's the square root of 2^160. Is that the calculation for all such schemes where the birthday paradox applies? In the wikipedia page, 23 marks the 50% line (is that what you mean be probable?), but it is 4 more than square root 366, a full 1% of the total more. – fredsbend Jan 20 at 1:09
  • 4
    @fredsbend, the actual formula for the birthday paradox is complicated, but as the numbers get bigger, taking the square root becomes an increasingly better approximation to it. When talking about cryptography, the numbers are so huge that the difference isn't worth worrying about. – Mark Jan 20 at 1:17
  • 6
    @fredsbend Technically, the square root of the number of possibilities gives you a 39.3% probability for collisions (1-exp(-1/2)), that's about where you see the probability go from negligable to negligably not. 1/2 sqrt(n) gives you 11.75%. 2 sqrt(n) gives you 86.5%. In cryptography the exact factor is usually ignored, and we just say that you need approximately sqrt(n) elements to see a probable collision. – Pieter Wuille Jan 20 at 1:17

A very relevant answer can be found here: Is Each Bitcoin Address Unique?

This is a question of the birthday attack on the hashes. Bitcoin addresses (assuming the "normal" style starting with a 1) encode 160 bit hashes, so the output space has a possible 2^160 hashes. Because its a hash function, we assume all outputs have equal probability of being output.

At the rate you gave in the OP, you would generate 1.971 * 10^11 addresses in 1 year. Using the approximate birthday formula n^2 / 2H, the probability of a collision in 1 year is thus roughly on the order of 10^-26. That is, basically 0. In 20 years that probability becomes around the order of 10^-24. Still basically 0. If all 8 billion people in the world generated addresses at that rate for 20 years, in total 3.1536 * 10^22 addresses would be generated. Even then, the probability of a collision is only around 0.0003. And remember that a collision like this is completely different from a targeted attack to find the private key of a specific address. If there was a collision, chances are overwhelming that there would be no funds ever sent to the address anyway, making the attack useless.

  • "A collision can't be a collision if there were no funds ever sent to the address" in regards to the last sentence of your answer. Other than that, great answer! Thank you! – Anonymous User Jan 19 at 23:25
  • @AnonymousUser You say you're able to generate 90 million addresses per 4 hours. MeshCollider is pointing out that that's actually irrelevant, as there aren't 90 million addresses being paid at that rate. – Pieter Wuille Jan 19 at 23:26
  • Oh gotcha, you may want to be more clear in that. Thanks again. – Anonymous User Jan 19 at 23:27

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.