<p>Replace wallet.dat with a saved copy</p>

CC BY-SA 4.0
2021-04-04T10:10:48.660Z
You mean replace the physical files inside the wallet directory?
s k
CC BY-SA 4.0
2021-04-04T10:45:04.640Z
@sk Yes. Make backups and restore backups, either manually or using the provided facilities. Practise first on non-valuable wallets until you are sure your actions have the effects you seek and no effects you consider harmful. On Ms-Windows see `%APPDATA%\Bitcoin\wallets\`
RedGrittyBrick
CC BY-SA 4.0
2021-04-03T15:12:19.063Z
2021-04-03T15:12:19.063Z
RedGrittyBrick
<p>Starting a <strong>Private Node</strong> using <code>bitcoin-qt</code>.</p>
<p>And then I generate a pair of keys for my own testing.</p>
<p>But unfortunately whenever I reset the node, it will generate a new pairs of keys, it makes my recursive test very tedious.</p>
<p>Is there a way for me to load a private key into my wallet instead of using <code>getnewaddress</code> every time and test with a new pair of keys?</p>

<bitcoin-core>
How can I load a specific private key into my wallet
s k
# How can I load a specific private key into my wallet

(Asked by: username_0 on 2021-04-03)

Starting a **Private Node** using `bitcoin-qt`.

And then I generate a pair of keys for my own testing.

But unfortunately whenever I reset the node, it will generate a new pairs of keys, it makes my recursive test very tedious.

Is there a way for me to load a private key into my wallet instead of using `getnewaddress` every time and test with a new pair of keys?

**Tags:** bitcoin-core


---

## 1 answers

### Answer by username_1 on 2021-04-03. Score: 1

Replace wallet.dat with a saved copy

> **Comments:**
> **username_0**: You mean replace the physical files inside the wallet directory?  
> **username_1**: @sk Yes. Make backups and restore backups, either manually or using the provided facilities. Practise first on non-valuable wallets until you are sure your actions have the effects you seek and no effects you consider harmful. On Ms-Windows see `%APPDATA%\Bitcoin\wallets\`  

---

