Reviewed Aug 2026
DE
BA-05 · LESSON 10

Timelocks

KEY DEFINITIONS

Terms used in this lesson

CLTV
CheckLockTimeVerify: a Bitcoin Script operation that enforces an absolute time or block-height condition.
CSV
CheckSequenceVerify: a Bitcoin Script operation that enforces a relative delay after an earlier output confirms.
BIP68
The consensus rule that gives version-2 transaction sequence fields relative block-height or relative-time meaning.
BIP65
The Bitcoin Improvement Proposal that introduced CHECKLOCKTIMEVERIFY for absolute height or time requirements.
CHECKLOCKTIMEVERIFY
The full name of CLTV, which checks an absolute height or time requirement.
BIP112
The Bitcoin Improvement Proposal that introduced CHECKSEQUENCEVERIFY for relative-delay requirements.
CHECKSEQUENCEVERIFY
The full name of CSV, which checks a relative height or time requirement.
MTP
Median Time Past: the median timestamp of the previous 11 blocks, used by Bitcoin for time-based lock evaluation.
Proof-of-work target
The maximum header-hash value accepted for a block; lowering it makes valid hashes harder to find.

nLockTime, sequence, CLTV, and CSV constrain when transactions or spending paths become valid.

45 min Difficulty 2/5 Not started

Loading lesson visuals...

01

Learn the idea

A timelock restricts when a transaction or input may become valid. BIP65 introduced CHECKLOCKTIMEVERIFY, or CLTV, for absolute requirements. BIP112 introduced CHECKSEQUENCEVERIFY, or CSV, for relative requirements. nLockTime is a transaction-level absolute height or time used with nonfinal sequence values. Relative locktime uses input sequence under BIP68. Median Time Past, or MTP, is the median timestamp of the previous 11 blocks and supplies the chain time used by time-based locks.

GUIDED EXPLANATION1/5 ideas inspected
1

Choose absolute or relative time

Absolute locks target a specific block height or timestamp. Relative locks target an age after the prior output confirms.

Inspect each idea before the worked example.
The worked example follows the explanation

Inspect every idea above to open it.

Important distinctionA timelocked transaction is automatically broadcast and executed when its timer expires.

Expiration only removes one validity barrier. Someone must still construct, authorize, broadcast, relay, and mine a valid transaction.

02
FINISH LEARNING FIRST

The questions unlock after every required learning activity

Inspect every guided idea, open the worked example, rebuild its mechanism, and complete the deterministic lesson tool. Your progress is saved automatically.