EIP-8295 Period-based state tiering (State Tiering by Periods)

No call decision · Fees & gas · EIP status Draft · created 2026-06-10

A proposal to charge extra gas when modifying state that hasn't been written to in a long time. It splits leaves into Active and Inactive tiers based on the last-written block recorded by EIP-8188, adding a surcharge only to Inactive writes. Read costs stay unchanged.

Why it is needed

Today's gas scheme charges the same write cost regardless of when the target state was last changed. But the real cost differs. Recently changed state is likely to remain in the performance-critical working set, while long-untouched state often falls onto the slow path, requiring deeper database lookups and heavier write overhead. Also, once state is created it remains forever, and the node operator keeps bearing the storage, indexing, and lookup costs, while the creator pays nothing further. Clients could track write age individually, but without an agreed-upon price, an attacker could cheaply touch long-dormant state to inflate every node's commit and storage costs. This proposal turns the last-written block information that EIP-8188 already records into a pricing signal, charging more gas to modify state that hasn't been written to in a long time. It creates an economic incentive for state hygiene without forcing deletion.

What changes

Today

After EIP-8295

Who is affected

In depth

Period and tier determination

PERIOD_LENGTH consecutive blocks are grouped into one period. current_period = max(0, (block_number - PERIOD_START_BLOCK) // PERIOD_LENGTH), and an item's last_written_period is computed the same way from EIP-8188's last_written_block. If period_age = current_period - last_written_period is less than INACTIVE_MIN_AGE, the item is ACTIVE; otherwise it is INACTIVE. The values of PERIOD_LENGTH and INACTIVE_MIN_AGE are still TBD, and PERIOD_START_BLOCK is derived from the activation block number of the hard fork in which this EIP takes effect. Block numbers are rounded to periods rather than used directly because the only resolution pricing needs is the Active/Inactive boundary, and within a single period current_period stays the same, so the tier only changes at period boundaries, making it easy for gas estimators to predict.

Which writes get surcharged, and by how much

The surcharge applies to every Inactive leaf an operation writes to, added on top of the base gas defined by EIP-8038 and EIP-8037. INACTIVE_ACCOUNT_WRITE_SURCHARGE applies to account leaves and INACTIVE_STORAGE_WRITE_SURCHARGE to storage slots, both of which must be greater than zero. When SSTORE changes an existing slot, the slot surcharge applies along with the surcharge on the account leaf updated via the storageRoot cascade. For CALL and CALLCODE with value transfer, both the sending and receiving accounts are targets; for nonce increments, the relevant account; and for CREATE and CREATE2, the creator account. Surcharges for value-transfer transactions and EIP-7702 signed authorizations are folded into intrinsic gas and evaluated at transaction validation time. Reads such as SLOAD, BALANCE, and EXT* opcodes, and value-less calls, are not targets. The tier is determined from the last_written_block at the start of the operation. After a write, last_written_block changes to the current block, making the leaf Active, so a given leaf is surcharged at most once per block.

New state creation is exempt

New accounts, new storage slots (going from zero to a nonzero value), and newly deployed code are not classified as Inactive and pay no surcharge. Creation cost is priced separately by EIP-8037. However, the exemption applies only to the newly created leaf itself. If an SSTORE 0 -> x on a dormant contract creates a new slot, the slot itself is a creation and carries no storage surcharge, but because the storageRoot cascade revives the existing account leaf, the account surcharge still applies. The source text states that the surcharge SHOULD be calibrated so that modifying Inactive state is not cheaper, in terms of block resources, than creating similarly sized new state. Otherwise there would be a contradiction where reviving old state uses the same node resources more cheaply. Since creation pricing is independent of the tiering mechanism, there is no cliff where creation cost spikes at INACTIVE_MIN_AGE, the point at which newly created state ages into Inactive.

The surcharge is regular-gas

The surcharge is regular-gas, not state-gas, because reviving Inactive state is an I/O operation, not state growth. It is therefore subject to EIP-7825's TX_MAX_GAS_LIMIT and is added to the block's regular-gas under EIP-8037's two-dimensional accounting. It is not refunded, and it remains spent even if the call frame is later reverted or aborted by an exception. This is consistent with EIP-8037, under which a revert rolls back state-gas but not regular-gas. If a frame reverts, the EIP-8188 last_written_block update also rolls back along with that frame's state. The surcharge stays spent, but since the leaf is still Inactive, writing to it again later incurs the surcharge once more.

Relationship to EIP-2929 warm/cold and access lists

Active and Inactive are update-age tiers determined by last_written_block and affect only write costs. EIP-2929's warm/cold concept, which tracks whether something has been accessed for the first time within a transaction, continues to apply to reads as before. For writes, the update-age tier is determined first, then the write cost for that tier applies. EIP-2930 access lists pre-warm addresses and slots to remove the first-access read burden within a transaction, but since read cost is independent of tier, the read pricing from access lists does not change. However, pre-warming must not erase the tier used for writes. SSTORE on a slot pre-warmed via an access list still pays the tiered write cost based on that slot's last_written_block.

Design rationale: fixed tiers, block-based periods, and the refresh game

The reason for using fixed per-tier gas constants instead of a multiplier-based approach is that the data resolution is coarse, at the level of "was this changed recently or not," and the estimator only needs to determine whether something is Active or Inactive. PERIOD_LENGTH is defined in blocks rather than wall-clock time, so if slot timing changes significantly, a follow-up EIP can re-derive the block count corresponding to the target period (about 6 months). The Active set is not enforced by the protocol, but since updating an entry within the W-block window costs gas, the total gas within the window divided by the minimum gas limit for a single update sets an upper bound, which economically rate-limits it. The incentive to periodically rewrite state to keep it Active is intentional design: whoever benefits from cheap writes in the future bears the maintenance cost. The surcharge should be large enough that neglect carries a real felt cost, but not so large that speculative bulk renewal writes become profitable.

Write-inactive is not read-inactive

This proposal prices only write age. A slot that is read every block but never rewritten remains in the Inactive tier. So this tier signal should not be read as "coldness" from an access perspective. This proposal does not move any state; moving it is a client storage policy matter. Clients that move Inactive state to slower or denser storage must separately account for read frequency, because placing frequently read Inactive state on a slow path can become a denial-of-service (DoS) vector. How to reconcile read frequency with write age is up to client storage policy and is out of scope for this proposal.

Current status and activation conditions

This EIP is in Draft status, so its contents may change. The values of PERIOD_LENGTH, INACTIVE_MIN_AGE, and the two surcharge constants are not yet set (TBD), and the test case section is still empty. Because this is a gas repricing without backward compatibility, it requires a scheduled network upgrade, and since it depends on EIP-8188 metadata, it must be activated in the same fork or later. Wallets and RPC providers need to update eth_estimateGas to determine the tier for each written item by its last_written_block and add the surcharge if it is Inactive. There is no core developer call record yet deciding this EIP's inclusion in a fork.

Original EIP · ← EIPs