<p>Bitcoin addresses can be created anywhere with any programming language.
they're just like the result of 1 + 1 = 2.</p>

<p>if you are looking for the function they're using for getting a new address here you go:
<a href="https://github.com/bitcoin/bitcoin/blob/4ad3b3c72c73d61e0a0cab541dca20acf651320d/src/wallet/rpcwallet.cpp#L135" rel="nofollow noreferrer">https://github.com/bitcoin/bitcoin/blob/4ad3b3c72c73d61e0a0cab541dca20acf651320d/src/wallet/rpcwallet.cpp#L135</a></p>

<p>When you make RPC call 'getnewaddress' that function will be called, and addresses keys are already generated (<code>keypool</code>) and saved into <code>wallet.dat</code> file.</p>

CC BY-SA 3.0
2018-03-22T15:18:13.580Z
2018-03-22T15:18:13.580Z
Tailer
<p>how does bitcoin core generate addresses and where can they be found in the data directory?</p>

CC BY-SA 3.0
2018-03-22T10:52:21.167Z
To generate addresses or to save the ones generated? Maybe you are talking about the wallet file itself.
Osias Jota
<bitcoin-core><address-generation>
how bitcoin core generate addresses?
Errol
# how bitcoin core generate addresses?

(Asked by: username_0 on 2018-03-22)

how does bitcoin core generate addresses and where can they be found in the data directory?

**Tags:** bitcoin-core, address-generation

> **Comments:**
> **username_1**: To generate addresses or to save the ones generated? Maybe you are talking about the wallet file itself.  

---

## 1 answers

### Answer by username_2 on 2018-03-22. Score: 1

Bitcoin addresses can be created anywhere with any programming language.
they're just like the result of 1 + 1 = 2.

if you are looking for the function they're using for getting a new address here you go:
<https://github.com/bitcoin/bitcoin/blob/4ad3b3c72c73d61e0a0cab541dca20acf651320d/src/wallet/rpcwallet.cpp#L135>

When you make RPC call 'getnewaddress' that function will be called, and addresses keys are already generated (`keypool`) and saved into `wallet.dat` file.


---

