/eth/v2/debug/beacon/states/{state_id}
method is a debug API endpoint in the Ethereum Beacon Chain that provides the complete BeaconState object for a given state identifier. This endpoint is essential for developers, validators, and network engineers who need to inspect the full state of the beacon chain for debugging, analysis, or monitoring purposes. The BeaconState contains comprehensive information about all validators, their balances, attestations, and other critical chain state data.
Parameters
{state_id}
: This parameter specifies the identifier of the beacon state to retrieve. The state identifier can be:head
— the canonical head in the node’s view (most recent state)genesis
— the initial state at chain genesisfinalized
— the most recent finalized statejustified
— the most recent justified state- A specific slot number (e.g.,
1000
) - A hex-encoded state root with 0x prefix (e.g.,
0xcf8e0d4e9587369b2301d0790347320302cc0943d5a1884560367e8208d920f2
)
Response
The response includes comprehensive state information:version
— the consensus version of the state (phase0, altair, bellatrix, capella, deneb, or electra)execution_optimistic
— boolean indicating if the response references an unverified execution payloadfinalized
— boolean indicating if the response references the finalized history of the chaindata
— the complete BeaconState object containing:genesis_time
— Unix timestamp of chain genesisgenesis_validators_root
— root hash of genesis validatorsslot
— current slot numberfork
— fork version informationlatest_block_header
— most recent block headerblock_roots
— array of recent block rootsstate_roots
— array of recent state rootsvalidators
— complete array of all validators with their propertiesbalances
— array of all validator balanceseth1_data
— Eth1 chain reference dataeth1_data_votes
— pending Eth1 data voteseth1_deposit_index
— current deposit index from Eth1previous_justified_checkpoint
— previous justified checkpointcurrent_justified_checkpoint
— current justified checkpointfinalized_checkpoint
— most recent finalized checkpoint
Usage notes
The/eth/v2/debug/beacon/states/{state_id}
method is a powerful debugging tool that provides complete visibility into the beacon chain state. This endpoint returns extensive data and should be used judiciously as responses can be very large, especially for mainnet states with hundreds of thousands of validators.
The endpoint supports both JSON and SSZ (Simple Serialize) response formats. To receive SSZ-encoded data, set the Accept
header to application/octet-stream
. SSZ format is more efficient for large state transfers.
This is a debug endpoint and may not be available on all beacon nodes. It requires significant computational resources to serialize the complete state, so response times may be longer than standard API calls.Path Parameters
State identifier. Can be one of: 'head' (canonical head in node's view), 'genesis', 'finalized', 'justified', <slot>, <hex encoded stateRoot with 0x prefix>.
Response
Success - Full BeaconState object retrieved
The consensus version of the state
phase0
, altair
, bellatrix
, capella
, deneb
, electra
"deneb"
True if the response references an unverified execution payload. Optimistic information may be invalidated at a later time.
false
True if the response references the finalized history of the chain, as determined by fork choice.
false
The full BeaconState object. The structure varies based on the consensus version.