Type in a script or op_code

Scripts

Scripts Describe The Locking Mechanism For UTXOs

Scripts are the programmatic instructions that, along with other transaction data, describes the locking & unlocking of Bitcoin. Each script is made up of op_codes & additional data such as public keys, signatures, hashes etc...Explore a few below!

Explore a few below!

P2PK

(pay to public key)

P2PK

Summary

The simplest common script for a direct transfer. A total of three op_codes are needed.

P2PKH

(pay to public key hash)

P2PKH

Summary

At one point the most universal script for simple, direct transfers. Still the default for pre-SegWit.

P2SH

(pay to script hash)

P2SH

Summary

The standard Legacy format for more complex transactions that require a script.

P2TR-KP

(pay to taproot - keypath)

P2TR-KP

Summary

A Taproot output spent with through the key path for a (likely) simple direct transfer

P2WPKH

(pay to witness public key hash)

P2WPKH

Summary

The standard SegWit script for direct transfers & the most common transaction type.

P2WSH

(pay to witness script hash)

P2WSH

Summary

The standard SegWit format for more complex transactions that require a script.

P2SH-TL

Pay to Script Hash (Timelock)

P2SH-TL

Summary

A P2SH output with a time-locked condition for spending

P2SH-HL

Pay to Script Hash (HashLock)

P2SH-HL

Summary

A P2SH output with a hash-locked condition for spending