# BIP32 HD Key Derivation

Derive BIP32 child private keys, xpubs, WIF keys, and Bitcoin mainnet/testnet P2PKH or SegWit addresses from a seed or xprv. Private and offline in your browser.

## Run it

- **CLI:** `gizza tool hd-key-derive "000102030405060708090a0b0c0d0e0f"`
- **Web:** https://gizza.ai/tools/hd-key-derive/
- **Agents:** machine-readable descriptor (parameters JSON Schema) at https://gizza.ai/tools/hd-key-derive/tool.json

## Inputs

- `seed` — Seed hex (optional) _(field)_
- `xprv` — xprv / tprv (optional) _(field)_
- `path` — Derivation path _(field)_
- `network` — Network _(field)_
- `address_type` — Address type _(field)_

## Output

- Derived key (text)

## Query parameters

Open the tool pre-filled and auto-run via URL:

- `seed` — Seed hex (optional)
- `xprv` — xprv / tprv (optional)
- `path` — Derivation path
- `network` — Network
- `address_type` — Address type

Example: `https://gizza.ai/tools/hd-key-derive/?seed=000102030405060708090a0b0c0d0e0f&xprv=xprv9s21ZrQH143K...&path=m%2F44%27%2F0%27%2F0%27%2F0%2F0&network=mainnet&address_type=p2pkh`

---

# BIP32 HD key derivation

Derive a Bitcoin BIP32 child private key from either a hex seed or an extended private key (`xprv` / `tprv`). The tool returns the child `xprv`, `xpub`, raw private key, compressed public key, WIF, fingerprint, and one Bitcoin address for the selected address format.

Everything runs locally in the browser. Private keys and seeds are not uploaded.

## Worked example

Use the BIP32 test-vector seed:

- `seed`: `000102030405060708090a0b0c0d0e0f`
- `path`: `m/0'`
- `network`: `mainnet`
- `address_type`: `p2pkh`

The output includes the BIP32 vector child key beginning with `xprv9uHRZZhk6KA...` and the matching `xpub68Gmy5Edvgi...`.

## Inputs

- Provide exactly one of `seed` or `xprv`.
- `path` must start with `m` and may use hardened suffixes `'`, `h`, or `H`.
- `network` changes xprv/xpub version bytes and address prefixes.
- `address_type` renders one address from the derived compressed public key: legacy P2PKH, wrapped SegWit, or native SegWit.

## Limits and edge cases

This is a Bitcoin-only BIP32 private-derivation tool. It does not accept mnemonics directly; use the BIP39 seed tool first, then paste the seed here. It does not derive from xpub-only watch-only keys, address ranges, ypub/zpub version bytes, or altcoin address formats.

<details>
<summary>Can I paste a mnemonic phrase?</summary>

No. First run the mnemonic through the BIP39 seed derivation tool, then paste the resulting 512-bit seed hex here. Keeping mnemonic validation separate keeps the wordlist/checksum logic in one place.
</details>

<details>
<summary>What is the difference between seed and xprv?</summary>

A seed is the root entropy used to create the master BIP32 key. An `xprv` or `tprv` is already an extended private key at some node. This tool can start from either one, but not both at the same time.
</details>

<details>
<summary>Which address type should I choose?</summary>

Use `p2pkh` for legacy `1...` or `m/n...` addresses, `p2sh_p2wpkh` for wrapped SegWit `3...` or `2...` addresses, and `p2wpkh` for native SegWit `bc1...` or `tb1...` addresses.
</details>

<details>
<summary>Can it derive many addresses at once?</summary>

No. Enter one explicit path, such as `m/84'/0'/0'/0/0`. To derive a range, rerun with the last index changed (`.../0`, `.../1`, and so on).
</details>

## Related tools

- [BIP39 Mnemonic Seed Phrase Generator](https://gizza.ai/tools/bip39-mnemonic-generator/): Generate a BIP39 mnemonic seed phrase (12–24 words) with checksum and derived 512-bit seed, entirely in your browser. Optional passphrase. Free and private.
- [BIP39 Seed Derivation](https://gizza.ai/tools/bip39-seed-derive/): Derive the 512-bit BIP39 seed from an existing mnemonic recovery phrase and optional passphrase, in your browser. Validates the wordlist and checksum. Free and private.
- [Extract Action Items from Meeting Notes](https://gizza.ai/tools/action-item-extractor/): Extract action items, owners, and decisions from meeting notes or daily notes with deterministic rules. Markdown checklist or JSON, private in-browser.
- [Amazon Order Analyzer](https://gizza.ai/tools/amazon-order-analyzer/): Paste an Amazon order-history CSV export to summarize total spend by month, top items, and category breakdowns. Browser-only, private, with Markdown or JSON output.
- [Base Decoder](https://gizza.ai/tools/base-decoder/): Auto-detect and decode Base16, Base32, Base45, Base58, Base64, and Base85 text, including nested layers, locally in your browser.
