Debug methods replay transactions and are computationally expensive. Availability and rate limits vary by node provider. Avoid calling these in hot paths.
Parameters
string
required
The 32-byte transaction hash to trace.
object
Optional tracing configuration.
Show Trace options
Show Trace options
string
Built-in tracer name.
"callTracer" returns a call tree. "prestateTracer" returns the pre-execution account state. Omit to use the default struct log tracer.object
Options for the selected tracer. For
"callTracer": { "onlyTopCall": true } skips internal calls.boolean
If
true, omits storage capture from struct logs. Reduces response size. Defaults to false.boolean
If
true, omits memory capture from struct logs. Reduces response size. Defaults to false.boolean
If
true, omits stack capture from struct logs. Defaults to false.string
Execution timeout as a Go duration string (e.g.,
"10s", "30s"). Defaults to "5s".Returns
object
The execution trace. Format depends on the
tracer option.Show Default struct log trace
Show Default struct log trace
number
Total gas provided for the transaction.
boolean
Whether the transaction failed (reverted).
string
Hex-encoded return value from the execution.
array
Array of struct log entries, one per EVM opcode executed.
Show Struct log fields
Show Struct log fields
number
Program counter position.
string
EVM opcode name (e.g.,
"PUSH1", "SLOAD").number
Remaining gas at this step.
number
Gas cost of this opcode.
number
Call depth (1 = top-level call).
array
EVM stack values at this step.
array
EVM memory contents as 32-byte chunks.
object
Contract storage changes at this step (slot → value).
Show callTracer result
Show callTracer result
string
Call type:
"CALL", "STATICCALL", "DELEGATECALL", or "CREATE".string
Sender address.
string
Recipient address.
string
ETH value sent with the call.
string
Gas provided for the call.
string
Gas actually consumed.
string
Call data sent.
string
Return data from the call.
string
Error message if the call reverted. Optional.
array
Array of nested call objects for internal calls.
Example
{
"jsonrpc": "2.0",
"method": "debug_traceTransaction",
"params": [
"0xb903239f8543d04b5dc1ba6579132b143087c68db1b2168786408fcbce568238",
{}
],
"id": 1
}
{
"jsonrpc": "2.0",
"method": "debug_traceTransaction",
"params": [
"0xb903239f8543d04b5dc1ba6579132b143087c68db1b2168786408fcbce568238",
{ "tracer": "callTracer" }
],
"id": 1
}
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"gas": 21000,
"failed": false,
"returnValue": "",
"structLogs": [
{
"pc": 0,
"op": "PUSH1",
"gas": 21000,
"gasCost": 3,
"depth": 1,
"stack": [],
"memory": [],
"storage": {}
}
]
}
}
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"type": "CALL",
"from": "0xd3cda913deb6f4967b2ef66ae97de114a83bcc01",
"to": "0x4200000000000000000000000000000000000006",
"value": "0x2c68af0bb14000",
"gas": "0x5208",
"gasUsed": "0x5208",
"input": "0x",
"output": "0x",
"calls": []
}
}