Skip to main content
Metal’s canonical block time has millisecond precision. JSON-RPC block responses expose the millisecond remainder in timestampMillisPart, while EVM block.timestamp remains second-resolution.

Read the canonical block time

The standard timestamp field contains seconds since the Unix epoch. Existing block decoders can continue to read this field at second resolution. For millisecond precision, read timestampMillisPart from block responses returned by eth_getBlockByNumber or eth_getBlockByHash, then compute:
Both fields are JSON-RPC quantities encoded as hexadecimal strings. Decode them before applying the formula. timestampMillisPart is in the range [0, 999].

EVM behavior

Contracts continue to read whole seconds from block.timestamp.
Do not use block.timestamp to distinguish blocks produced within the same second. Consecutive blocks produced within that second may expose the same value. Deadlines, vesting cliffs, and other time windows continue to operate at whole-second precision.

Monotonicity

Canonical block time is strictly increasing. Consensus rejects a block whose computed time is less than or equal to its parent’s.

Wall-clock skew tolerance

Validators check proposed block timestamps against a 60-second window on either side of their local wall clock. A block more than 60 seconds ahead or behind that clock is rejected. The timestamp must also be strictly greater than the parent’s. This tolerance allows for differences between validator clocks while bounding both forward-dating and back-dating.