/eth/v2/debug/beacon/heads
method is a debug API endpoint in the Ethereum Beacon Chain that retrieves all possible chain heads, which are the leaves of the fork choice tree. This endpoint is crucial for understanding the current state of fork choice in the beacon chain, showing all potential chain tips that the node is currently tracking and considering as possible canonical chains.
Get you own node endpoint todayStart for free and get your app to production levels immediately. No credit card required.You can sign up with your GitHub, X, Google, or Microsoft account.
Parameters
This endpoint does not require any parameters.Response
The response provides an array of all current chain heads:data
— array of chain head objects, each containing:root
— the block root (32-byte hex string) uniquely identifying this chain headslot
— the slot number of this chain headexecution_optimistic
— boolean indicating whether this head references an unverified execution payload
Usage notes
The/eth/v2/debug/beacon/heads
method provides critical insight into the fork choice mechanism of the beacon chain. In a healthy network, there is typically one primary head representing the canonical chain, but during network partitions, high latency periods, or chain reorganizations, multiple heads may exist temporarily.
This endpoint is particularly useful for:
- Network monitoring — detecting potential chain splits or forks
- Validator operations — understanding which chain heads are being considered for block production
- Debugging consensus issues — identifying when and why multiple chain heads exist
- Fork choice analysis — studying how the beacon chain resolves competing chains
- Network latency causing temporary disagreement between nodes
- Competing blocks being produced for the same slot
- Chain reorganizations as the network converges on the canonical chain
execution_optimistic
flag is important for understanding whether a head has been fully verified with the execution layer. Optimistic heads may be invalidated if the execution payload is later found to be invalid.
This is a debug endpoint and may not be available on all beacon nodes. It provides a real-time view of the fork choice state and is essential for advanced monitoring and debugging of consensus layer behavior.Response
Success - Fork choice leaves retrieved
Array of all chain heads (fork choice leaves)