<p><a href="https://bitcointalk.org/index.php?topic=25804.0">Vanitygen</a> is a command-line tool that can be used to generate random bitcoin addresses. It also has OpenCL-compatible GPU version called oclvanitygen. Both can be built from source, <a href="https://github.com/samr7/vanitygen">GitHub</a>, and both are included in the <a href="http://www.sendspace.com/file/pjgrfj">Windows binary package</a>. PGP signature <a href="http://insight.gotdns.org/~samr7/vanitygen-0.17-win.zip.asc">here</a>.</p>

CC BY-SA 3.0
2013-11-17T20:01:50.947Z
i would think that vanitygen is the best performing address generator, but i don't have numbers to compare. see also http://bitcoin.stackexchange.com/a/2088/1098 for vanitygen speed
hmundt
CC BY-SA 3.0
2011-11-02T10:03:44.623Z
Good suggestion, but I need to favour performance over looks. Generating vanity addresses will throw away perfectly acceptable addresses leading to wasted time.
Gary
CC BY-SA 3.0
2011-11-02T18:24:28.453Z
@Gary Rowe But couldn't you just provide and empty regular expression (something like `1*`) and generate a ton of addresses?
nmat
CC BY-SA 3.0
2011-11-03T09:13:16.670Z
@nmat Good point - hadn't considered that
Gary
CC BY-SA 3.0
2011-11-01T15:48:58.967Z
2011-11-01T19:19:20.017Z
2011-11-01T19:19:20.017Z
Serith
<p>You can use <a href="https://www.bitaddress.org">bitaddress.org</a>. It is a single HTML file so you can save it and generate lots of addresses offline using their Bulk Wallet tab. The biggest problem here is Javascript performance. With current hardware you can generate around 1000 addresses per minute. If you are willing to wait several hours (maybe leave the computer working overnight), this can solve your problem.</p>

CC BY-SA 3.0
2011-11-02T10:01:40.510Z
Interesting approach, however I'd be looking to create them in blocks of several hundred thousand in a short space of time (a few minutes) so I'd need a compiled execution environment.
Gary
CC BY-SA 3.0
2011-11-01T18:36:13.057Z
2011-11-01T18:36:13.057Z
nmat
<p>If you want to generate a lot of keys in the wallet.dat, use <a href="https://en.bitcoin.it/wiki/Running_Bitcoin#Command-line_arguments" rel="nofollow">command line parameter</a>:</p>

<pre><code>-keypool=&lt;n&gt;       Set key pool size to &lt;n&gt; (default: 100)
</code></pre>

<p>Then you can extract the results with <a href="https://bitcointalk.org/index.php?topic=34028.0" rel="nofollow">Pywallet</a>.</p>

<p>If you want to make them separate, you will have to use a cryptography library that supports secp256k1 ECDSA, like the <a href="http://www.bouncycastle.org/" rel="nofollow">Bouncy Castle</a>. Simply generate private keys, use the library to generate public keys from them, and then convert them to classic Bitcoin address using <a href="https://en.bitcoin.it/wiki/Address" rel="nofollow">this algorithm</a> (requires libraries that support SHA256 and RIPEMD-160).</p>

CC BY-SA 3.0
2011-11-01T14:56:31.167Z
Hmmm. So roll my own then? Not a standard feature of bitcoind to produce them outside of the wallet.dat?
Gary
CC BY-SA 3.0
2011-11-01T15:11:39.147Z
Wouldn't know, what do you want to do with those addresses anyway?
ThePiachu
CC BY-SA 3.0
2011-11-01T15:45:35.973Z
One possible use case would be to pre-load an online service with a bucket of transaction addresses. No private keys stored on the server.
Gary
CC BY-SA 3.0
2011-11-01T18:22:20.397Z
I guess you could also use Pywallet for this, edited my answer.
ThePiachu
CC BY-SA 3.0
2011-11-01T14:35:41.867Z
2011-11-01T18:21:53.113Z
2011-11-01T18:21:53.113Z
ThePiachu
<p>I would like to generate a large number of <a href="https://en.bitcoin.it/wiki/Address">public Bitcoin addresses</a> (several hundred thousand) quickly and efficiently into a simple text file. What would be the easiest way to get this done? I'm just wondering if there are any particular scripts or services that handle this already without having to roll my own.</p>

<development><address>
How can I generate a large number of Bitcoin addresses?
Gary
# How can I generate a large number of Bitcoin addresses?

(Asked by: username_0 on 2011-11-01)

I would like to generate a large number of [public Bitcoin addresses](https://en.bitcoin.it/wiki/Address) (several hundred thousand) quickly and efficiently into a simple text file. What would be the easiest way to get this done? I'm just wondering if there are any particular scripts or services that handle this already without having to roll my own.

**Tags:** development, address


---

## 3 answers

### Answer by username_4 on 2011-11-01. Score: 6 | Accepted answer

If you want to generate a lot of keys in the wallet.dat, use [command line parameter](https://en.bitcoin.it/wiki/Running_Bitcoin#Command-line_arguments):

```
-keypool=<n>       Set key pool size to <n> (default: 100)

```

Then you can extract the results with [Pywallet](https://bitcointalk.org/index.php?topic=34028.0).

If you want to make them separate, you will have to use a cryptography library that supports secp256k1 ECDSA, like the [Bouncy Castle](http://www.bouncycastle.org/). Simply generate private keys, use the library to generate public keys from them, and then convert them to classic Bitcoin address using [this algorithm](https://en.bitcoin.it/wiki/Address) (requires libraries that support SHA256 and RIPEMD-160).

> **Comments:**
> **username_0**: Hmmm. So roll my own then? Not a standard feature of bitcoind to produce them outside of the wallet.dat?  
> **username_4**: Wouldn't know, what do you want to do with those addresses anyway?  
> **username_0**: One possible use case would be to pre-load an online service with a bucket of transaction addresses. No private keys stored on the server.  
> **username_4**: I guess you could also use Pywallet for this, edited my answer.  

---

### Answer by username_1 on 2011-11-01. Score: 9

[Vanitygen](https://bitcointalk.org/index.php?topic=25804.0) is a command-line tool that can be used to generate random bitcoin addresses. It also has OpenCL-compatible GPU version called oclvanitygen. Both can be built from source, [GitHub](https://github.com/samr7/vanitygen), and both are included in the [Windows binary package](http://www.sendspace.com/file/pjgrfj). PGP signature [here](http://insight.gotdns.org/~samr7/vanitygen-0.17-win.zip.asc).

> **Comments:**
> **username_0**: Good suggestion, but I need to favour performance over looks. Generating vanity addresses will throw away perfectly acceptable addresses leading to wasted time.  
> **username_3**: @username_0 Rowe But couldn't you just provide and empty regular expression (something like `1*`) and generate a ton of addresses?  
> **username_0**: @username_3 Good point - hadn't considered that  
> **username_2**: i would think that vanitygen is the best performing address generator, but i don't have numbers to compare. see also http://bitcoin.stackexchange.com/a/2088/1098 for vanitygen speed  

---

### Answer by username_3 on 2011-11-01. Score: 8

You can use [bitaddress.org](https://www.bitaddress.org). It is a single HTML file so you can save it and generate lots of addresses offline using their Bulk Wallet tab. The biggest problem here is Javascript performance. With current hardware you can generate around 1000 addresses per minute. If you are willing to wait several hours (maybe leave the computer working overnight), this can solve your problem.

> **Comments:**
> **username_0**: Interesting approach, however I'd be looking to create them in blocks of several hundred thousand in a short space of time (a few minutes) so I'd need a compiled execution environment.  

---

