RoadmapsProjects
Sign in./start

Learn

RoadmapsProjects

Contribute

DiscoverIssues

Account

Sign in./start-building

Become an Open Source Builder. Learn. Build. Contribute.

Learn

RoadmapsProjectsStart Building

Contribute

DiscoverIssues

Account

Sign inDashboardSettings

Legal

PrivacyTerms

© 2026 Pull // all rights reserved

PrivacyTerms

lesson // bitcoin

Taproot & Tapscript

Key-path and script-path spends, MAST, and Schnorr signatures.

intermediate6 days

Public lesson — sign in to track progress on this roadmap.

./sign-in

On this page

Learning objectives

  • Contrast key-path and script-path Taproot spends
  • Explain why unused scripts stay private
  • Connect Schnorr signatures to Taproot outputs

study // plan

Lessons are primers. Depth comes from required reading, interactive labs, reflection, and a hands-on check with evidence — the BOSS study pattern.

Research on Bitcoin Search
BIP341BIP340Taproot

Required reading

  • bookMastering Bitcoin

    Ch. 7: Authorization and Authentication

Interactive lab // Decoding Bitcoin

Open these Bitcoin Dev Project modules and tools before (or alongside) the graded lab. Capture evidence from the interactive path — do not only skim Pull.

  • Decoding Bitcoin: Introduction to Taproot

    Interactive Taproot on-ramp before BIP-341 deep reading.

  • Decoding Bitcoin: Schnorr signatures

    Pair with tagged hashes — why Taproot prefers Schnorr.

  • Decoding Bitcoin: Tagged hashes
  • Decoding Bitcoin: Taproot roadmap

Reflection prompts

  1. Explain Taproot & Tapscript to a teammate without jargon — what problem does it solve?
  2. What would break in production if you misunderstood Taproot & Tapscript?
  3. After the Decoding Bitcoin Taproot intro, what is one privacy win of key-path spends vs revealing a script path?

Lab // Taproot interactive + regtest

Complete Decoding Bitcoin's Introduction to Taproot (and Schnorr or tagged hashes if needed). Then on regtest create or inspect a Taproot address / key-path spend and note what appears on-chain vs what stays hidden.

evidence required

  • ·Screenshot or notes from Decoding Bitcoin Introduction to Taproot
  • ·Regtest address or tx showing a bc1p / witness v1 output (or descriptor)
  • ·One sentence contrasting key-path vs script-path privacy

Taproot (SegWit v1) lets coins be spent with a single Schnorr signature in the common case, while still allowing complex scripts as hidden alternatives. Addresses look like bc1p... (Bech32m).

Why this matters

Taproot improves privacy and efficiency for multisig-like policies and future Lightning constructions. Modern wallet descriptors increasingly default to Taproot.

Analogy

A Taproot output is a house with a normal front door (key path) and several secret side doors (script leaves). Neighbors usually only see you use the front door, they never learn which side doors exist unless you open one.

Two ways to spend

Key-path versus script-path Taproot spends
Key-path spends look like simple single-sig; script-path reveals only the used leaf.
  1. Key-path: sign with the tweaked output key, cheapest and most private
  2. Script-path: reveal a script leaf + merkle proof + satisfy that script

Loading diagram…

The output key commits to an optional script tree without revealing it upfront.

Tapscript

Script-path leaves use Tapscript, Script with Taproot-specific rules and Schnorr CHECKSIG behavior. Multisig and timelock policies can live in leaves while cooperative spends stay on the key path (especially with MuSig-style aggregation).

Privacy wins when you cooperate

If parties always cooperate, they can prefer key-path spends so onlookers cannot tell a complex policy was involved.

Common mistakes

  • Treating Taproot as “just a new address” without descriptors/backup of the script tree
  • Losing the internal key / merkle info needed for script-path recovery
  • Mixing Bech32 (v0) and Bech32m (v1) validation

Internal key and tweak

Taproot output keys commit to an internal key tweaked by a merkle root of scripts (or a nothing-up-my-sleeve tweak when no scripts). Cooperative MuSig-style key aggregation can make complex custody look like a single key on-chain when everyone agrees.

When script path appears

Script path reveals:

  • The leaf script used
  • A merkle proof to the tweak
  • Satisfaction data (signatures, preimages, etc.)

Unused leaves remain hidden, a privacy and fungibility win versus revealing a full redeem script every time (as with many P2SH spends).

Wallet responsibilities

If you support Taproot script trees, backups must include enough data to reconstruct spends for every leaf you might need, not only the key path.

Worked mental model

Re-read the diagrams in this lesson once out loud in plain language. If you cannot explain the flow to a friend without jargon, pause and revisit Mastering Bitcoin / Mastering Lightning chapters linked in Resources. Chapter references are intentional, not decorative.

Hands-on habit

Every protocol idea should be paired with one local experiment:

  1. Reproduce the happy path on regtest (or Polar for Lightning)
  2. Break it on purpose (wrong fee, expired invoice, offline peer)
  3. Write down what error you saw and which layer produced it (wallet, node, mempool, peer)

That habit turns reading into builder instinct.

Glossary check

Pick three terms from this lesson and define them in one sentence each without opening notes. Weak definitions mean the lesson is not finished yet.

Resource order

Use Resources in order: narrative book chapter first, then BIP/BOLT for precision, then implementation docs for commands. Jumping straight to RPC flags without the mental model creates brittle knowledge.

Next steps

Study multisig and timelocks, the policies often hidden inside Taproot trees and Lightning scripts.

further reading

  • bookMastering Bitcoin

    Ch. 8: Signatures

  • bipBIP-341 Taproot
  • bipBIP-340 Schnorr

progress // sign in

Reading is public. Sign in to mark lessons complete, sync across devices, and unlock your roadmap.

./sign-in-to-track
prevSegWit & Bech32nextMultisig & Timelocks

On this page

Press Shift + ? for keyboard shortcuts.

Press R to research on Bitcoin Search.