Skip to content

eth_newBlockFilter ​

served · same as reth

Creates a filter for new blocks and returns its ID. Poll it with eth_getFilterChanges.

When to use ​

Use it to learn about new blocks over HTTP. Over a WebSocket, eth_subscribe with newHeads is simpler.

Example ​

bash
curl -s -X POST -H 'Content-Type: application/json' \
  --data '{"jsonrpc": "2.0", "id": 1, "method": "eth_newBlockFilter", "params": []}' \
  http://127.0.0.1:8547
json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "eth_newBlockFilter",
  "params": []
}

Response ​

Live mainnet, 2026-10-14. Checked against reth 2.7: equal.

json
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": "0x41252af4e569ca5bf411510c4955f11e"
}

The filter id is random. The answer changes with time, so it is compared by shape (keys and types; for a list, its first item), not by value.

Full response

Parameters ​

None.

Returns ​

The filter ID, 16 random bytes as hex.

Notes and limits ​

  • Each poll returns the hashes of the new blocks.
  • The same limits as log filters apply. The node keeps at most 1 024 filters (256 for one client), and a filter expires 5 minutes after its last poll.

Errors ​

CodeMessageWhen
-32603too many filtersThe client already has 256 filters.

Compared with reth ​

The live example above gives the same answer on Cinder and on reth 2.7.

eth_getFilterChanges, eth_uninstallFilter, eth_subscribe.

Schema (OpenRPC) ​

The official specification: eth_newBlockFilter in ethereum/execution-apis.

Result: string
json
{
  "pattern": "^0x(0|[1-9a-f][0-9a-f]*)$",
  "title": "hex encoded unsigned integer",
  "type": "string"
}