Skip to main content

eth_getLogs RPC Method

Returns an array of all logs matching a given filter object.

Updated on
Mar 27, 2026
Please be aware that the block range limit for this RPC method is 5 blocks for users on the Free Trial plan and 10,000 blocks for those on paid plans. Consider dividing your queries into smaller segments to enhance response times and manage errors more effectively. For further details on the block range limit and strategies for mitigating it, please consult the FAQ

Parameters

object
object

The transaction call object which contains the following fields

fromBlock
string

The block number as a string in hexadecimal format or tags. The supported tag values include earliest for the earliest/genesis block, latest for the latest mined block, pending for the pending state/transactions, safe for the most recent secure block, and finalized for the most recent secure block accepted by more than 2/3 of validators

toBlock
string

The block number as a string in hexadecimal format or tags. The supported tag values include earliest for the earliest/genesis block, latest for the latest mined block, pending for the pending state/transactions, safe for the most recent secure block, and finalized for the most recent secure block accepted by more than 2/3 of validators

address
string

The contract address or a list of addresses from which logs should originate

topics
array

An array of DATA topics and also, the topics are order-dependent. Visit this official page to learn more about topics

blockHash
string

With the addition of EIP-234, blockHash is a new filter option that restricts the logs returned to the block number referenced in the blockHash. Using the blockHash field is equivalent to setting the fromBlock and toBlock to the block number the blockHash references. If blockHash is present in the filter criteria, neither fromBlock nor toBlock is allowed

Returns

result
array

An array of log objects, or an empty array if nothing has changed since last poll

address
string

The address from which this log originated

topics
array

An array of (0 to 4) 32 Bytes DATA of indexed log arguments. (In solidity: The first topic is the hash of the signature of the event (e.g. Deposit(address,bytes32,uint256)), except you declared the event with the anonymous specifier)

data
string

It contains one or more 32 Bytes non-indexed arguments of the log

blockNumber
string

The block number where this log was in. null when its pending. Null when it's a pending log

blockTimestamp
string

The block timestamp where this log was included encoded as hexadecimal

transactionHash
string

The hash of the transaction from which this log was created from. null if the log is pending

transactionIndex
string

The integer of the transaction's index position that the log was created from. Null when it's a pending log

blockHash
string

The hash of the block where this log was in. Null when it's a pending log

logIndex
string

The integer of the log index position in the block. Null when it's a pending log

removed
boolean

It is true if log was removed, due to a chain reorganization and false if it's a valid log

Request
Response
1
{
2
"jsonrpc": "2.0",
3
"id": 1,
4
"result": [
5
{
6
"address": "0x4200000000000000000000000000000000000006",
7
"topics": [
8
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
9
"0x00000000000000000000000065081cb48d74a32e9ccfed75164b8c09972dbcf1",
10
"0x000000000000000000000000bc9f05bd2cb80f47f66444acd737ab1c66efba3b"
11
],
12
"data": "0x00000000000000000000000000000000000000000000000000001ce37ce88e85",
13
"blockNumber": "0x26cb170",
14
"transactionHash": "0x1f7d7a104380670016abac815a01820029b366a9c3ef82da9f655e3dcaa950bc",
15
"transactionIndex": "0x5",
16
"blockHash": "0x2f19a36a7a2583d703804282af6eda018bee7d3d66662180d5615607dc92153f",
17
"blockTimestamp": "0x6995d137",
18
"logIndex": "0x7",
19
"removed": false
20
},
21
{
22
"address": "0x4200000000000000000000000000000000000006",
23
"topics": [
24
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
25
"0x00000000000000000000000065081cb48d74a32e9ccfed75164b8c09972dbcf1",
26
"0x000000000000000000000000bc9f05bd2cb80f47f66444acd737ab1c66efba3b"
27
],
28
"data": "0x00000000000000000000000000000000000000000000000000000715cc0fc715",
29
"blockNumber": "0x26cb170",
30
"transactionHash": "0x1f7d7a104380670016abac815a01820029b366a9c3ef82da9f655e3dcaa950bc",
31
"transactionIndex": "0x5",
32
"blockHash": "0x2f19a36a7a2583d703804282af6eda018bee7d3d66662180d5615607dc92153f",
33
"blockTimestamp": "0x6995d137",
34
"logIndex": "0xa",
35
"removed": false
36
},
37
{
38
"address": "0x4200000000000000000000000000000000000006",
39
"topics": [
40
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
41
"0x000000000000000000000000bc9f05bd2cb80f47f66444acd737ab1c66efba3b",
42
"0x0000000000000000000000005719f31b0e76f72bac3c62ffbb2f4598f3bfa754"
43
],
44
"data": "0x0000000000000000000000000000000000000000000000000000000d0f749c19",
45
"blockNumber": "0x26cb170",
46
"transactionHash": "0x1f7d7a104380670016abac815a01820029b366a9c3ef82da9f655e3dcaa950bc",
47
"transactionIndex": "0x5",
48
"blockHash": "0x2f19a36a7a2583d703804282af6eda018bee7d3d66662180d5615607dc92153f",
49
"blockTimestamp": "0x6995d137",
50
"logIndex": "0xd",
51
"removed": false
52
},
53
{
54
"address": "0x4200000000000000000000000000000000000006",
55
"topics": [
56
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
57
"0x000000000000000000000000bc9f05bd2cb80f47f66444acd737ab1c66efba3b",
58
"0x00000000000000000000000065081cb48d74a32e9ccfed75164b8c09972dbcf1"
59
],
60
"data": "0x00000000000000000000000000000000000000000000000000000023adc6aa0e",
61
"blockNumber": "0x26cb170",
62
"transactionHash": "0x1f7d7a104380670016abac815a01820029b366a9c3ef82da9f655e3dcaa950bc",
63
"transactionIndex": "0x5",
64
"blockHash": "0x2f19a36a7a2583d703804282af6eda018bee7d3d66662180d5615607dc92153f",
65
"blockTimestamp": "0x6995d137",
66
"logIndex": "0x10",
67
"removed": false
68
},
69
{
70
"address": "0x4200000000000000000000000000000000000006",
71
"topics": [
72
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
73
"0x000000000000000000000000bc9f05bd2cb80f47f66444acd737ab1c66efba3b",
74
"0x00000000000000000000000065081cb48d74a32e9ccfed75164b8c09972dbcf1"
75
],
76
"data": "0x000000000000000000000000000000000000000000000000000023c88bbd4d48",
77
"blockNumber": "0x26cb170",
78
"transactionHash": "0x1f7d7a104380670016abac815a01820029b366a9c3ef82da9f655e3dcaa950bc",
79
"transactionIndex": "0x5",
80
"blockHash": "0x2f19a36a7a2583d703804282af6eda018bee7d3d66662180d5615607dc92153f",
81
"blockTimestamp": "0x6995d137",
82
"logIndex": "0x12",
83
"removed": false
84
}
85
]
86
}
1
{
2
"jsonrpc": "2.0",
3
"id": 1,
4
"result": [
5
{
6
"address": "0x4200000000000000000000000000000000000006",
7
"topics": [
8
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
9
"0x00000000000000000000000065081cb48d74a32e9ccfed75164b8c09972dbcf1",
10
"0x000000000000000000000000bc9f05bd2cb80f47f66444acd737ab1c66efba3b"
11
],
12
"data": "0x00000000000000000000000000000000000000000000000000001ce37ce88e85",
13
"blockNumber": "0x26cb170",
14
"transactionHash": "0x1f7d7a104380670016abac815a01820029b366a9c3ef82da9f655e3dcaa950bc",
15
"transactionIndex": "0x5",
16
"blockHash": "0x2f19a36a7a2583d703804282af6eda018bee7d3d66662180d5615607dc92153f",
17
"blockTimestamp": "0x6995d137",
18
"logIndex": "0x7",
19
"removed": false
20
},
21
{
22
"address": "0x4200000000000000000000000000000000000006",
23
"topics": [
24
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
25
"0x00000000000000000000000065081cb48d74a32e9ccfed75164b8c09972dbcf1",
26
"0x000000000000000000000000bc9f05bd2cb80f47f66444acd737ab1c66efba3b"
27
],
28
"data": "0x00000000000000000000000000000000000000000000000000000715cc0fc715",
29
"blockNumber": "0x26cb170",
30
"transactionHash": "0x1f7d7a104380670016abac815a01820029b366a9c3ef82da9f655e3dcaa950bc",
31
"transactionIndex": "0x5",
32
"blockHash": "0x2f19a36a7a2583d703804282af6eda018bee7d3d66662180d5615607dc92153f",
33
"blockTimestamp": "0x6995d137",
34
"logIndex": "0xa",
35
"removed": false
36
},
37
{
38
"address": "0x4200000000000000000000000000000000000006",
39
"topics": [
40
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
41
"0x000000000000000000000000bc9f05bd2cb80f47f66444acd737ab1c66efba3b",
42
"0x0000000000000000000000005719f31b0e76f72bac3c62ffbb2f4598f3bfa754"
43
],
44
"data": "0x0000000000000000000000000000000000000000000000000000000d0f749c19",
45
"blockNumber": "0x26cb170",
46
"transactionHash": "0x1f7d7a104380670016abac815a01820029b366a9c3ef82da9f655e3dcaa950bc",
47
"transactionIndex": "0x5",
48
"blockHash": "0x2f19a36a7a2583d703804282af6eda018bee7d3d66662180d5615607dc92153f",
49
"blockTimestamp": "0x6995d137",
50
"logIndex": "0xd",
51
"removed": false
52
},
53
{
54
"address": "0x4200000000000000000000000000000000000006",
55
"topics": [
56
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
57
"0x000000000000000000000000bc9f05bd2cb80f47f66444acd737ab1c66efba3b",
58
"0x00000000000000000000000065081cb48d74a32e9ccfed75164b8c09972dbcf1"
59
],
60
"data": "0x00000000000000000000000000000000000000000000000000000023adc6aa0e",
61
"blockNumber": "0x26cb170",
62
"transactionHash": "0x1f7d7a104380670016abac815a01820029b366a9c3ef82da9f655e3dcaa950bc",
63
"transactionIndex": "0x5",
64
"blockHash": "0x2f19a36a7a2583d703804282af6eda018bee7d3d66662180d5615607dc92153f",
65
"blockTimestamp": "0x6995d137",
66
"logIndex": "0x10",
67
"removed": false
68
},
69
{
70
"address": "0x4200000000000000000000000000000000000006",
71
"topics": [
72
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
73
"0x000000000000000000000000bc9f05bd2cb80f47f66444acd737ab1c66efba3b",
74
"0x00000000000000000000000065081cb48d74a32e9ccfed75164b8c09972dbcf1"
75
],
76
"data": "0x000000000000000000000000000000000000000000000000000023c88bbd4d48",
77
"blockNumber": "0x26cb170",
78
"transactionHash": "0x1f7d7a104380670016abac815a01820029b366a9c3ef82da9f655e3dcaa950bc",
79
"transactionIndex": "0x5",
80
"blockHash": "0x2f19a36a7a2583d703804282af6eda018bee7d3d66662180d5615607dc92153f",
81
"blockTimestamp": "0x6995d137",
82
"logIndex": "0x12",
83
"removed": false
84
}
85
]
86
}
Don't have an account yet?
Create your Quicknode endpoint in seconds and start building
Get started for free