{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "eth_getUncleCountByBlockHash",
  "params": [
    "0xc6ef2fc5426d6ad6fd9e2a26abeab0aa2411b7ab17f30a99d3cb96aed1d1055b"
  ]
}
{
  "id": 1,
  "jsonrpc": "2.0",
  "result": "0x1"
}
Defined in the Ethereum JSON-RPC Specification
Returns the number of uncles in a block by block hash.

Parameters

blockHash
string
required
Hash of a block (32 bytes).

Returns

result
string
The number of uncles in this block as a hexadecimal string.
{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "eth_getUncleCountByBlockHash",
  "params": [
    "0xc6ef2fc5426d6ad6fd9e2a26abeab0aa2411b7ab17f30a99d3cb96aed1d1055b"
  ]
}
{
  "id": 1,
  "jsonrpc": "2.0",
  "result": "0x1"
}

Error Handling

CodeMessageDescription
-32602Invalid block hashThe provided block hash is invalid
4100Requested method not supportedThe method is not supported by the wallet
Uncle blocks are blocks that were mined but not included in the main blockchain. This method returns their count for a specific block.