L0vdL0vd

eth_getUncleCountByBlockNumber

Returns the number of uncles in a block, by number. Always 0 after the Merge.

Archive · Works on any past block

curl https://eth.l0vdinfra.com/YOUR_KEY \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","id":1,"method":"eth_getUncleCountByBlockNumber","params":["0xb71b80"]}'

Example response

{
  "jsonrpc": "2.0",
  "id": 1,
  "result": "0x1"
}
Params and your endpoint

Parameters

blockstringrequired
Block number in hex (e.g. "0x1208a5f") or a tag: "latest", "safe", "finalized", "earliest" or "pending". L0vd endpoints run archive nodes, so any historical block works.

Returns

string Uncle count, hex.

When to use it

Count uncle (ommer) blocks included by a pre-Merge Ethereum block, for mining-era analytics.

How to read the result

Hex integer. Always 0x0 for blocks after the Merge (September 2022).

Tips

  • Relevant only to historical Proof of Work data.

Related methods