Bitcoin Takeover / BIPs / BIP 113
BIP 113
Median time-past as endpoint for lock-time calculations
Deployed Activated soft fork Consensus (soft fork) Specification Assigned 2015-08-10
Lock times measured against median-time-past instead of a miner-chosen timestamp.
From the BIP’s abstract
This BIP is a proposal to redefine the semantics used in determining a time-locked transaction's eligibility for inclusion in a block. The median of the last 11 blocks is used instead of the block's timestamp, ensuring that it increases monotonically with each block.
Read BIP 113 on GitHubFind in explorerActivated on mainnet
CSV · Relative timelocks — block 419,328, 2016-07-04.
“Spendable N blocks after this coin confirmed” (relative timelocks) plus median-time-past for lock times. Lightning's penalty and timeout paths rely on it.
Sources: BIP 68, “Relative lock-time using consensus-enforced sequence numbers”, bitcoin/bips (commit a7f9132, 2026-11-17) · BIP 112, “CHECKSEQUENCEVERIFY”, bitcoin/bips (commit a7f9132, 2026-11-17) · BIP 113, “Median time-past as endpoint for lock-time calculations”, bitcoin/bips (commit a7f9132, 2026-11-17) · Bitcoin Core, src/kernel/chainparams.cpp — mainnet BIP34/65/66/CSV/SegWit heights · mempool.space, block 419,328
In Bitcoin Core
Median time past lock-time calculations have been implemented since v0.12.1, and has been buried since v0.19.0.