Skip to main content

eth_getTransactionByBlockNumberAndIndex RPC Method

Returns information about a transaction given a block number and transaction index position.

Updated on
Apr 09, 2026

Parameters

blockNumber
string
REQUIRED

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

index
string
REQUIRED

An integer of the transaction index position encoded as a hexadecimal

Returns

object
object | null

The transaction response object, or null if no transaction is found:

blockHash
string | null

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

blockNumber
string | null

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

blockTimestamp
string

The timestamp of the block where this transaction was included, encoded as hexadecimal.

from
string

The address of the sender

gas
string

The gas provided by the sender, encoded as hexadecimal

gasPrice
string

The gas price provided by the sender in wei, encoded as hexadecimal

hash
string

The hash of the transaction

input
string

The data sent along with the transaction

nonce
string

The number of transactions made by the sender prior to this one encoded as hexadecimal

to
string | null

The address of the receiver. null when it's a contract creation transaction

transactionIndex
string | null

The integer of the transaction's index position that the log was created from, encoded as hexadecimal. null when it's a pending log

value
string

The value transferred in wei encoded as hexadecimal

type
string

The transaction type

v
string

The standardized V field of the signature

r
string

The R field of the signature

s
string

The S field of the signature

yParity
string

(Optional) Coordinate of key used in signature

sourceHash
string

The hash of the source transaction that created this transaction

mint
string

The minting event associated with the transaction

depositReceiptVersion
string

The version of a deposit receipt

chainId
string

(Optional) The chain ID of the transaction, encoded as hexadecimal

Request
Response
1
{
2
"jsonrpc": "2.0",
3
"id": 1,
4
"result": {
5
"blockHash": "0x294ee346b64498b6f9375e5ceaf04dc0dd8f40f1ba4247e598d0ca4cb57e7152",
6
"blockNumber": "0x1b15f50",
7
"transactionIndex": "0x0",
8
"hash": "0xcfa85227cb945061e31d9c8c7707f01d940e85b3d9f59c57e2248c3ff308dcd2",
9
"from": "0xdeaddeaddeaddeaddeaddeaddeaddeaddead0001",
10
"to": "0x4200000000000000000000000000000000000015",
11
"input": "0x3db6be2b00000558000c5fc500000000000000050000000069ce8d2700000000017a4f23000000000000000000000000000000000000000000000000000000000c7ba4080000000000000000000000000000000000000000000000000000000000b60a39e98cd37b62cc5287580404ef0e9af5a1283cd7e4ff0c924ace3716dc74c6bb4c0000000000000000000000001ffda89c755f6d4af069897d77ccabb580fd412a000000000000013aa2d138370190",
12
"nonce": "0x1b15f51",
13
"value": "0x0",
14
"gas": "0xf4240",
15
"gasPrice": "0x0",
16
"chainId": "0xb67d2",
17
"type": "0x7e",
18
"v": "0x0",
19
"r": "0x0",
20
"s": "0x0",
21
"mint": "0x0",
22
"sourceHash": "0x6304a3145e256a6e6777cb722a5cb9a043e895034a6d4d1ce751b2f04b0231f9",
23
"depositReceiptVersion": "0x1"
24
}
25
}
1
{
2
"jsonrpc": "2.0",
3
"id": 1,
4
"result": {
5
"blockHash": "0x294ee346b64498b6f9375e5ceaf04dc0dd8f40f1ba4247e598d0ca4cb57e7152",
6
"blockNumber": "0x1b15f50",
7
"transactionIndex": "0x0",
8
"hash": "0xcfa85227cb945061e31d9c8c7707f01d940e85b3d9f59c57e2248c3ff308dcd2",
9
"from": "0xdeaddeaddeaddeaddeaddeaddeaddeaddead0001",
10
"to": "0x4200000000000000000000000000000000000015",
11
"input": "0x3db6be2b00000558000c5fc500000000000000050000000069ce8d2700000000017a4f23000000000000000000000000000000000000000000000000000000000c7ba4080000000000000000000000000000000000000000000000000000000000b60a39e98cd37b62cc5287580404ef0e9af5a1283cd7e4ff0c924ace3716dc74c6bb4c0000000000000000000000001ffda89c755f6d4af069897d77ccabb580fd412a000000000000013aa2d138370190",
12
"nonce": "0x1b15f51",
13
"value": "0x0",
14
"gas": "0xf4240",
15
"gasPrice": "0x0",
16
"chainId": "0xb67d2",
17
"type": "0x7e",
18
"v": "0x0",
19
"r": "0x0",
20
"s": "0x0",
21
"mint": "0x0",
22
"sourceHash": "0x6304a3145e256a6e6777cb722a5cb9a043e895034a6d4d1ce751b2f04b0231f9",
23
"depositReceiptVersion": "0x1"
24
}
25
}
Don't have an account yet?
Create your Quicknode endpoint in seconds and start building
Get started for free