Home › Glossary › Output descriptor

Output descriptor

Also called: output script descriptor, descriptor, wallet descriptor, descriptors, descriptor wallet, wpkh(), tr().

An output descriptor is a short text string that says exactly which scripts and addresses a wallet uses: script type, keys and derivation paths.

An output descriptor (in full, an output script descriptor) is a compact, human-readable description of a set of Bitcoin output scripts. It records the three things a seed phrase leaves out: the script type, the keys involved and their derivation paths.

What one looks like

wpkh([d34db33f/84h/0h/0h]xpub6.../0/*)#checksum
  • wpkh(...) is the script expression: native SegWit P2WPKH.
  • [d34db33f/84h/0h/0h] is the key origin: the master key's fingerprint and the path to the account.
  • xpub6... is the account xpub, and /0/* means every receiving address below it.
  • #checksum is an 8-character checksum that catches typos.

Other expressions include pkh(), sh(), wsh(), multi(), sortedmulti(), tr() and multi_a(), and they nest: sh(wpkh(...)) is wrapped SegWit and wsh(sortedmulti(2,...)) with three keys is a 2-of-3 multisig.

The BIPs

Pieter Wuille and Ava Chow specified descriptors as a family: BIP 380 (syntax, key expressions and checksums), BIP 381 to BIP 385 (legacy, SegWit, multisig, combo(), raw() and addr()), BIP 386 (tr() for Taproot) and BIP 387 (multi_a() for tapscript multisig). BIP 389 proposes /<0;1>/* to cover receive and change addresses in one descriptor, and Miniscript (BIP 379) extends the language to complex spending policies.

Why it matters

A descriptor plus its keys is a complete wallet backup: any compatible wallet can find every address without guessing paths or script types. Bitcoin Core's wallet is built on descriptors. Read the output descriptors guide.

BIPs that define Output descriptor

  • BIP 380: Output Script Descriptors General Operation: Deployed. Output script descriptors are a compact text language for describing exactly which addresses a wallet owns and how they are spent. This document defines their general syntax and checksum, giving…
  • BIP 382: Segwit Output Script Descriptors: Deployed. Defines the descriptor functions for native SegWit outputs, covering both single-key addresses and script-based ones. With these, wallets can precisely describe and back up SegWit wallets, including…
  • BIP 386 (Taproot descriptors): tr() Output Script Descriptors: Deployed. Defines the descriptor function for Taproot outputs, combining a main key with an optional tree of alternative spending conditions. This gives wallets a standard way to describe, back up and recover…
  • BIP 383: Multisig Output Script Descriptors: Deployed. Defines descriptor functions for multisignature setups, where a certain number of keys out of a group must sign. One version keeps keys in the given order and another sorts them automatically, which…
  • BIP 381: Non-Segwit Output Script Descriptors: Deployed. Defines the descriptor functions for Bitcoin's older address types: pay-to-public-key, pay-to-public-key-hash (classic addresses starting with '1'), and pay-to-script-hash (addresses starting with…
  • BIP 385: raw() and addr() Output Script Descriptors: Deployed. Defines two simple descriptor functions: one that wraps an arbitrary raw script and one that wraps a plain address. They let wallets track coins in formats not otherwise covered, or watch an address…
  • BIP 387: Tapscript Multisig Output Script Descriptors: Deployed. Defines descriptor functions for multisignature setups inside Taproot scripts, which require a different construction than older multisig. One form keeps keys in the given order and the other sorts…
  • BIP 389: Multipath Descriptor Key Expressions: Draft. Extends descriptors so one key expression can represent several related derivation paths at once, such as a wallet's receiving and change addresses. This shortens wallet backups and avoids having to…

Related terms

  • Miniscript: Miniscript is a structured way to write Bitcoin Script, specified in BIP 379, that makes complex spending conditions easy to analyze, combine and sign.
  • xpub (extended public key): An xpub is a BIP 32 extended public key: a public key plus chain code that can derive every address in an account, but can't spend from them.
  • Derivation path: A derivation path like m/84'/0'/0'/0/0 locates one key inside an HD wallet: the sequence of child indexes taken from the master key.
  • Multisig: Multisig (multi-signature) locks bitcoin so that M of N chosen keys must sign to spend it, for example any 2 of 3 keys kept in different places.
  • Seed phrase: A seed phrase is a list of 12 to 24 words, defined by BIP 39, that encodes the random number from which a wallet derives all of its keys.

Learn more

Guides