<p>From what I heard, Bitcoin uses a <a href="http://en.wikipedia.org/wiki/Hash_table" rel="nofollow">hash table</a> for storing its addresses when checking new blocks and transactions for whether they are related to our wallet or not. This data structure should allow for fairly efficient data handling, meaning that it should scale fairly well with growing amount of addresses.</p>

<p>So, for any sane amount of addresses, Bitcoin should scale well. Generally, the size of the wallet.dat is small in comparison to how much RAM even a low-end machine has, so it shouldn't be much of an issue.</p>

CC BY-SA 3.0
2012-10-02T10:54:13.997Z
2012-10-02T10:54:13.997Z
ThePiachu
<p>There isn't a problem with storage but there is a problem with the computation time necessary when constructing spend transactions which involve a large number of inputs from your wallet. </p>

<p>This is a problem that is evidenced by those who run Martingale betting bots against SatoshiDICE for instance.  After they get several thousand bitcoin addresses with transactions, their subsequent bet transactions that draw from those coins start to crawl.</p>

<p>A future release of the Bitcoin.org client will address this by switching from BDB to LevelDB.  Additionally targeted for future release is "ultraprune" which will lessen the storage requirements as well.</p>

<p>In the meantime, InstaWallet is one service that was able to come up with a solution that mitigated the problem.  They might be able to offer some suggestions. </p>

CC BY-SA 3.0
2012-10-02T22:13:29.897Z
2012-10-02T22:13:29.897Z
Stephen Gornick
<p>I am working on a project which may end up generating a few hundred (or even more) bitcoin addresses a day. From my understanding in theory there is no limit on the number of bitcoin addresses in a wallet, but i fear to run into scalability issues with bitcoind on the long run.</p>

<p>Will RAM or CPU usage increase significantly? Is there any known limit of the number of addresses?</p>

<p>Note: Probably 60-80% of these addresses will never receive any transaction. Don't know if this makes a difference.</p>

<wallet><bitcoind><scalability>
How many addresses can be handled reliable in one wallet?
TripleSpeeder
# How many addresses can be handled reliable in one wallet?

(Asked by: username_0 on 2012-10-02)

I am working on a project which may end up generating a few hundred (or even more) bitcoin addresses a day. From my understanding in theory there is no limit on the number of bitcoin addresses in a wallet, but i fear to run into scalability issues with bitcoind on the long run.

Will RAM or CPU usage increase significantly? Is there any known limit of the number of addresses?

Note: Probably 60-80% of these addresses will never receive any transaction. Don't know if this makes a difference.

**Tags:** wallet, bitcoind, scalability


---

## 2 answers

### Answer by username_2 on 2012-10-02. Score: 4 | Accepted answer

There isn't a problem with storage but there is a problem with the computation time necessary when constructing spend transactions which involve a large number of inputs from your wallet.

This is a problem that is evidenced by those who run Martingale betting bots against SatoshiDICE for instance. After they get several thousand bitcoin addresses with transactions, their subsequent bet transactions that draw from those coins start to crawl.

A future release of the Bitcoin.org client will address this by switching from BDB to LevelDB. Additionally targeted for future release is "ultraprune" which will lessen the storage requirements as well.

In the meantime, InstaWallet is one service that was able to come up with a solution that mitigated the problem. They might be able to offer some suggestions.


---

### Answer by username_1 on 2012-10-02. Score: 3

From what I heard, Bitcoin uses a [hash table](http://en.wikipedia.org/wiki/Hash_table) for storing its addresses when checking new blocks and transactions for whether they are related to our wallet or not. This data structure should allow for fairly efficient data handling, meaning that it should scale fairly well with growing amount of addresses.

So, for any sane amount of addresses, Bitcoin should scale well. Generally, the size of the wallet.dat is small in comparison to how much RAM even a low-end machine has, so it shouldn't be much of an issue.


---

