<p>Yes. Each input has its own signature with which to sign, so as long as you possess the private keys (or a master private key above the account level), you can add those inputs into any transaction you want.</p>

CC BY-SA 4.0
2019-10-22T12:44:53.667Z
2019-10-22T12:44:53.667Z
tgunnoe
<p>Say I have 1000 users, each one with its own account with paths m/49'/0'/{user.id}', and I am controlling received/sent funds.</p>

<p>Could I collect all the funds (i.e. inputs) in a sole fat transaction output even though they belong to different accounts of the same HD Wallet?</p>

CC BY-SA 4.0
2019-10-22T15:18:28.787Z
note that since you are using hardened keys at the user level public derivation won't be possible. if you instead use non-hardened keys at that level you can store the xpub for m/49'/0'/ on the server and and derive addresses for user level accounts. it's safer than storing the xpriv on a server which you would need to do for hardened derivation.
Abdussamad
CC BY-SA 4.0
2019-10-22T16:28:41.287Z
It might be, but that'd deviate from the standard, which would make the wallet much harder to export and manipulate in a different scenario, isn't it?
Moliholy
<bip32-hd-wallets>
Can I add inputs from different accounts coming from the same Bitcoin HDWallet?
Moliholy
# Can I add inputs from different accounts coming from the same Bitcoin HDWallet?

(Asked by: username_0 on 2019-10-22)

Say I have 1000 users, each one with its own account with paths m/49'/0'/{user.id}', and I am controlling received/sent funds.

Could I collect all the funds (i.e. inputs) in a sole fat transaction output even though they belong to different accounts of the same HD Wallet?

**Tags:** bip32-hd-wallets

> **Comments:**
> **username_1**: note that since you are using hardened keys at the user level public derivation won't be possible. if you instead use non-hardened keys at that level you can store the xpub for m/49'/0'/ on the server and and derive addresses for user level accounts. it's safer than storing the xpriv on a server which you would need to do for hardened derivation.  
> **username_0**: It might be, but that'd deviate from the standard, which would make the wallet much harder to export and manipulate in a different scenario, isn't it?  

---

## 1 answers

### Answer by username_2 on 2019-10-22. Score: 2 | Accepted answer

Yes. Each input has its own signature with which to sign, so as long as you possess the private keys (or a master private key above the account level), you can add those inputs into any transaction you want.


---

