Descriptor Checksum
Eight characters appended to an output descriptor that catch transcription errors.
Basically
A descriptor checksum is an 8-character code at the end of a Bitcoin wallet's address instructions. It spots typing and copying mistakes before your wallet uses those instructions.
Key Takeaways
- A descriptor checksum is an 8-character alphanumeric string added after a # symbol to an output descriptor. It lets wallet software detect typos, copy errors and corruption before importing or using the descriptor.
- The checksum uses a BCH error-detecting code similar to bech32 encoding. It guarantees detection of all single-character errors and all errors involving up to 3 symbol substitutions in descriptors up to 49,154 characters long.
- BIP 380 defines the checksum, which is mandatory when importing descriptors into Bitcoin Core and other descriptor wallets. Wallet migration and backup workflows therefore cannot silently accept corrupted data.
What Is a Descriptor Checksum?
A descriptor checksum is a short error-detection code added to a Bitcoin output descriptor string. Output descriptors define exactly how a wallet derives addresses and constructs spending conditions. A single wrong character could make a wallet generate entirely different addresses and send funds to locations nobody controls, so the checksum catches mistakes before they become costly.
The checksum appears at the end of a descriptor, separated by a # character. A simple pay-to-witness-public-key-hash descriptor provides one example of this format.
The 8 characters after the # are computed from every preceding character in the descriptor string. Wallet software rejects the descriptor on import if any character is altered, added or removed, because the checksum no longer matches.
How It Works
BIP 380, the specification for output descriptor general operation, defines the descriptor checksum algorithm. The algorithm uses a BCH (Bose-Chaudhuri-Hocquenghem) error-detecting code, from the same family of codes that underpins bech32 address encoding.
The Polymod Function
A polymod function operating over GF(32), a finite field with 32 elements, forms the core of the checksum. Five 40-bit generator constants define the function's error-detecting polynomial.
These generator constants differ from those used in bech32 address encoding. Descriptor checksums must cover a larger input space: the full set of printable ASCII characters used in descriptors, rather than just the limited bech32 data alphabet.
Checksum Character Set
The checksum contains 8 characters. Its output uses the same 32-character alphabet as bech32.
The alphabet deliberately excludes characters that are easily confused with one another, such as 1/l, 0/o and b/6. These exclusions reduce the chance of transcription errors surviving the checksum validation step.
Verification
Wallet software verifies a descriptor by feeding the entire string, including the checksum characters but excluding the # separator, through the same polymod function. A result of 1 means the checksum is valid. Any other value indicates corruption.
Error Detection Capabilities
The BCH code used in descriptor checksums provides strong mathematical guarantees about which errors it can detect. BIP 380 sets out these guarantees.
These properties make the checksum highly reliable for catching common practical mistakes, including copy-paste truncation and manual transcription errors. They also catch encoding mismatches and data corruption during storage or transmission.
Why It Matters
Output descriptors are the modern standard for wallet portability and backup. Users pass descriptor strings between systems when migrating between wallet software, restoring from backups or configuring multisig setups. Without a checksum, a single corrupted character could silently cause a wallet to derive an entirely different set of addresses.
A multisig wallet descriptor with a typo in one extended public key (xpub) shows the risk. Without checksum validation, the wallet might appear to function normally and generate addresses that look valid. Those addresses would not match the intended spending policy, and any funds sent to them could be permanently unrecoverable.
The checksum transforms this silent failure into an immediate, loud error. Bitcoin Core requires a valid checksum when importing descriptors through the importdescriptors RPC and rejects any descriptor whose checksum does not match. Descriptor-based workflows are therefore significantly safer than the older approach of importing raw keys or xpubs without integrity verification.
Wallet Migration
Users moving from one descriptor wallet to another export their descriptors with checksums and import them into the new software. The receiving wallet validates the checksum before accepting the descriptor, ensuring an error-free migration. HD wallets particularly need this check because a single wrong character in a derivation path could generate thousands of incorrect addresses.
Multisig Coordination
A multisig wallet setup requires sharing extended public keys and agreeing on a descriptor template among all participants. The checksum ensures that every participant works with identical descriptor strings, preventing a miscommunicated key from locking funds in an unreachable script.
Backup Verification
Descriptor backups stored on paper, in encrypted files or on hardware wallets can degrade over time or suffer transcription errors. The checksum immediately reveals whether a stored descriptor is intact during restoration, long before any funds are at risk.
Automated Systems
Payment processors, exchanges and custody platforms programmatically generate or import descriptors. Checksum validation gives these systems a first line of defence against software bugs, network corruption or database errors that might alter descriptor data in transit or at rest.
Checksum Sensitivity to Notation
The descriptor checksum is computed over the exact character string, not the semantic meaning of the descriptor. Two descriptors that produce identical addresses but use different notation, such as h versus ' for hardened derivation, will have different checksums. Wallet software must normalise descriptors to a canonical form before comparing checksums, and you should be aware that the same wallet configuration can have multiple valid checksum representations.
Not a Security Mechanism
Descriptor checksums detect accidental errors, not malicious tampering. An attacker who can modify a descriptor string can also recompute a valid checksum for the altered version, so the checksum provides data integrity rather than authentication. Security-critical workflows need additional verification, such as digital signatures or secure comparison over authenticated channels.
Import Behavior Varies
Bitcoin Core requires a valid checksum for descriptor imports, but not all wallet software enforces this requirement equally. Some wallets accept descriptors without checksums or with invalid checksums, reducing the safety benefit. You should always use software that validates checksums on import and use Bitcoin Core's getdescriptorinfo RPC to compute and verify checksums when in doubt.
The glossary entry is for informational purposes only and does not constitute financial or investment advice. You should always do your own research before using any protocol or technology.