What are the chances of an address collision? when for example 1 billion people are using bitcoin and on average they generate 10 address per person. also what exactly will happen when address collision occurs?

Chances are still negligible when 1 billion people are using it? also can't I just run some kind of bots, that randomly generate addresses to see ifthey have funds in them?

Given your example of 1 billion users at 10 addresses each: There are 2^160 or about 1,460,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000 possible addresses In your scenario, 1,000,000,000 people are using 10 addresses each for a total of 10,000,000,000 possible addresses 10,000,000,000 / 2^160 should yield the probability of a collision occurring 10,000,000,000 / 2^160 = 0.00000000000000000000000000000000000000684 So the chances of a collision occurring in your scenario are approximately 0.000000000000000000000000000000000000684% See why we don't consider collisions an issue?

See this question on the StackExchange site for a rundown of why brute-forcing private keys (which is essentially what you're describing) is also a no-go.

can't I just run some kind of bots, that randomly generate addresses to see if they have funds in them?

I'm an independent developer working on bitcoin-core , making my living off community donations.If you like my work, please consider donating yourself:

Yes, chances remain negligible. You could run your bot, but it'd be a waste of electricity. Chances are you'd wait the lifetime of the universe before finding a collision.

Chances are still negligible when 1 billion people are using it? also can't I just run some kind of bots, that randomly generate addresses to see ifthey have funds in them?

But probability also says, I could have a success on my first run? isn't it?

Yes, chances remain negligible. You could run your bot, but it'd be a waste of electricity. Chances are you'd wait the lifetime of the universe before finding a collision.

Chances are still negligible when 1 billion people are using it? also can't I just run some kind of bots, that randomly generate addresses to see ifthey have funds in them?

Not to mention that even if you could find addresses, if the block reward went to zero TODAY without a billion people using Bitcoin, even today's minute amounts of transaction fees would still be worth more per cpu/gpu/fpga cycle than if you'd spent that same cycle looking for populated addresses. Given that the same equipment you'd use in such an address search should, because of the similarity of the tasks, be capable of mining as well, it would be more profitable to use that equipment for mining purposes.

Yes, chances remain negligible. You could run your bot, but it'd be a waste of electricity. Chances are you'd wait the lifetime of the universe before finding a collision.

Chances are still negligible when 1 billion people are using it? also can't I just run some kind of bots, that randomly generate addresses to see ifthey have funds in them?

But probability also says, I could have a success on my first run? isn't it?

If we have a "perfect" hash function with output size n, and we have p messages to hash (individual message length is not important), then probability of collision is about p^2 / 2^(n+1) (this is an approximation which is valid for "small" p, i.e. substantially smaller than 2n/2). For instance, with SHA-256 (n=256) and one billion messages (p=109) then the probability is about 4.3*10-60. A mass-murderer space rock happens about once every 30 million years on average. This leads to a probability of such an event occurring in the next second to about 10-15. That's 45 orders of magnitude more probable than the SHA-256 collision [in 1b messages]. Briefly stated, if you find SHA-256 collisions scary then your priorities are wrong.

The odds in colliding with a specific address is 1 in 2^160.If there are a billion users and each have one million active addresses (1 quadrillion funded addresses in the blockchain) the odds in colliding with any address would be roughly 1 in 2^110 (1*10^33).Vanitygen can produce 20 million keypairs per second. Lets say you build a super ASIC on 12nm (4 generations ahead of current tech) process that could create, validate, and steal one trillion keypairs per second (1 TK/s). That would be about 50,000x more powerful than faster GPU today. Lets also say you built a thousand of them and ran them continually with no downtime 24/7/365. In 1 year you could brute force 3*10^28 possible addresses.If there are 1 quadrillion funded addresses you would still have a ~1% chance of colliding with a random funded address in the next 1,000 years.TL/DR Vlad's answer works.

It's a lot more likely that you're struck by lightning or a meteor. So get your priorities straight and worry about that.

But probability also says, I could have a success on my first run? isn't it?