SIGHASH_ANYPREVOUT (BIP 118)

Definition: SIGHASH_ANYPREVOUT is a proposed Taproot signature mode in BIP 118 that would let certain tapscript signatures authorize a spend without committing to the exact previous transaction output (UTXO) being spent. It is designed for protocols that need a signed transaction to remain usable across compatible channel states. BIP 118 is still a draft soft-fork proposal; this behavior is not part of Bitcoin’s deployed consensus rules.1

Proposal status BIP 118 is marked Draft. Deployment details remain unfinished; it is not active on Bitcoin mainnet.
What it changes Adds opt-in tapscript public-key types for SIGHASH_ANYPREVOUT and SIGHASH_ANYPREVOUTANYSCRIPT.
Potential use A proposed building block for eltoo-style payment-channel updates, including a possible Lightning Network design.
Primary sources
Directories Bitcoin Technology & Infrastructure · Bitcoin Directory

How the proposed signature mode works

A normal Bitcoin input signature commits to the transaction data defined by its signature-hash mode, including which previous output the input spends. That outpoint ties the signature to a particular UTXO. BIP 118 proposes a separate public-key type for tapscript, so only scripts that explicitly use that type can use the new behavior. A compatible signature could then be rebound to another previous output that satisfies the remaining script and transaction commitments.1

BIP 118 defines two related modes. SIGHASH_ANYPREVOUT omits the specific outpoint but continues to commit to important input data, including its amount, scriptPubKey, and sequence. SIGHASH_ANYPREVOUTANYSCRIPT omits more input-specific data, including the outpoint, amount, scriptPubKey, and tapscript leaf hash. Both still commit to transaction-level and output data according to the proposal’s rules. The second mode is more flexible, but that flexibility makes careful key and script design especially important.1

Mode Previous-output data committed to Design implication
Ordinary Taproot signature The signature’s selected hash mode normally commits to the exact outpoint. A signature is tied to the designated input unless another standard mode changes those commitments.
SIGHASH_ANYPREVOUT Omits the outpoint while retaining the amount, scriptPubKey, sequence, and tapscript commitment described in BIP 118. Can rebind to a compatible output under the same required spending conditions.
SIGHASH_ANYPREVOUTANYSCRIPT Also omits the amount, scriptPubKey, and tapscript leaf hash, in addition to the outpoint. Allows broader rebinding and requires a protocol to provide the necessary safety constraints.

“Any previous output” therefore does not mean that an arbitrary Bitcoin output can be spent with the signature. The address must opt in through an appropriate tapscript path, and the signature still has to satisfy the proposal’s remaining commitments and script conditions. BIP 118 does not add a general-purpose signature that bypasses the owner’s authorization.1

Why eltoo uses the idea

Payment-channel protocols keep a sequence of signed states that can be settled on-chain if participants stop cooperating. The eltoo paper proposes a replacement mechanism that uses state numbers to make older channel states unenforceable once a later state is confirmed. This differs from Lightning’s penalty-based channel construction. Its update and settlement transactions may need to remain valid when the exact preceding channel state changes. A signature that can be rebound to compatible outputs is one proposed way to support that behavior, which is why BIP 118 is associated with eltoo and Lightning channel research.1, 2

This is a potential protocol use, not a description of a feature users can currently enable in a Bitcoin wallet. The eltoo paper is a design proposal, and BIP 118’s deployment section remains incomplete. Existing Lightning implementations should not be assumed to use ANYPREVOUT unless their specifications and software explicitly say so.1, 2

Security considerations

Removing an outpoint commitment creates signature-replay cases that ordinary signatures are designed to prevent. Depending on which mode is used, a signature may be valid for another UTXO with the same relevant spending conditions, or for a wider set of outputs using a reused BIP 118 key. A protocol must constrain key reuse and transaction construction so that a valid signature cannot authorize an unintended spend.1

The proposal also discusses transaction malleability: changing which compatible input is used can produce a different transaction ID even when the signed outputs remain the same. Channel protocols that depend on transaction identifiers must account for this behavior. BIP 118’s security discussion is part of the proposal’s design; it should not be treated as a production security guarantee or as evidence that the feature has been activated.1

History

  • February 28, 2017: BIP 118 was assigned as a proposal for new signature behavior in Bitcoin scripts.1
  • 2018: The eltoo paper described a payment-channel update design that motivated a reusable signature approach; BIP 118’s revision notes connect its ANYPREVOUT behavior to this use case.1, 2
  • November 15, 2026: BIP 118 remains marked Draft, with deployment details not specified in the proposal.1

Page updated: November 15, 2026.

Related Terms

Related Articles

See Also

Crypto Tools – A curated list by CryptoGloss

Sources

  1. Bitcoin Improvement Proposals. “BIP 118: SIGHASH_ANYPREVOUT for Taproot Scripts.” GitHub. Accessed November 15, 2026. https://github.com/bitcoin/bips/blob/master/bip-0118.mediawiki.
  2. Decker, Christian, Rusty Russell, and Olaoluwa Osuntokun. “eltoo: A Simple Layer 2 Protocol for Bitcoin.” 2018. https://blockstream.com/eltoo.pdf.