~$ crypto-under-the-hood

# The machinery behind the coins

~/notes / reading on-chain data

How Wallets Derive Addresses

One seed phrase produces unlimited addresses through a defined path. Understanding the derivation explains several recovery problems.

Ivan Kruse · · 2 min

A modern wallet does not hold one key. It holds a seed from which unlimited keys are generated deterministically.

The chain of derivation

Entropy. A random number, generated by the device.

The mnemonic. That number encoded as words from a fixed list, with a checksum in the final word.

The seed. Derived from the mnemonic, optionally combined with a passphrase.

The master key. Derived from the seed.

Child keys. Derived from the master key along a path, and from those, further children.

Each step is deterministic. The same mnemonic always produces the same keys, which is what makes recovery possible.

The path

Derivation follows a structured path specifying purpose, coin type, account, change and index.

Different wallets use different defaults. That is the source of a specific and confusing recovery failure: restoring a mnemonic in a wallet that uses a different default path produces valid addresses that are not the ones you funded.

The wallet is working correctly. It is deriving different children from the same parent.

The passphrase

An optional additional word combined with the mnemonic before seed derivation.

With a passphrase, the same twelve or twenty-four words produce a completely different wallet. That is the feature: plausible deniability and additional security.

It is also the most common cause of unrecoverable loss after simple phrase loss, because a forgotten passphrase has no checksum, no constraint on length, and nothing to search.

What this explains

Why restoring produces an empty wallet. Either the wrong derivation path, or a passphrase that is not being supplied.

Why recording the first receiving address matters. It lets you verify a restore instantly without funding anything.

Why documenting that a passphrase exists is essential. Not the passphrase itself, which stays secret, but the fact of it. That single note turns an impossible recovery into a difficult one.

Why the same phrase works across chains. The coin type field in the path separates them, and one seed backs up everything.

The practical checklist

Record, alongside the phrase: the wallet application used, the derivation path if non-standard, whether a passphrase exists, and the first receiving address of each account.

None of those are secrets. All of them can be stored with a document that is safe to keep normally.

And test the restore before funding. Wipe, restore, confirm the address matches. That single step catches every problem described here while it is still fixable.

For the working balance held at a venue rather than in a wallet, none of this applies, and recovery is an identity-verification process instead. Both models have failure modes and they are completely different ones, which is why splitting holdings between them is more robust than committing to either.

# Corrections and technical nitpicks are welcome. Send them over. They get published with the fix.

derivationwalletsrecovery

# related notes