BitcoinMachine
TRANSACTIONS / CONSENSUS
Bitcoin Script
Bitcoin Script is a stack-based, Forth-like, intentionally limited scripting language. Every transaction output contains a scriptPubKey (locking script). Every input contains a scriptSig (unlocking script). To spend, the combined script must execute without error and leave a non-zero value on top of the stack. There are no loops — Script is not Turing complete by design.
Choose a template or enter your own scripts. Step through execution one opcode at a time to see exactly how the stack evolves. The output is VALID if execution completes with a single truthy value on the stack.
STACK MACHINE SIMULATORstep through or run all
IDLE
STACK
Stack empty.
BITCOIN SCRIPT OPCODES
OPCODEBYTESTACK EFFECTDESCRIPTION
OP_RETURN — provably unspendable: Any output with a script starting with OP_RETURN is provably unspendable. Nodes prune these from the UTXO set immediately. This is used to embed arbitrary data in the blockchain (e.g. for timestamping, colored coins, or Omni Layer) without bloating the UTXO set permanently.