trace_block | Base

Base API method trace_block provides a comprehensive trace of all transactions included in a specific block. This method is crucial for developers, auditors, and blockchain analysts who need to understand the detailed execution flow of every transaction within a block, including contract calls, state changes, and event emissions. It offers a holistic view of the block's impact on the Ethereum Virtual Machine (EVM) and the blockchain state.


  • blockNumber or blockHash — The number or hash of the block you wish to trace, specified as a hexadecimal string or a decimal number. This identifies the specific block whose transactions you want to analyze in detail.


  • result — An array containing the trace data for each transaction in the specified block. Each element in the array represents the trace of a single transaction, detailing every operation executed, such as calls to other contracts, value transfers, and the execution outcomes.

Use case

The trace_block method is invaluable for conducting in-depth block analyses. Developers can use it to debug and optimize the interactions of multiple transactions within a block, auditors can employ it to ensure the security and integrity of all transactions in a block, and analysts might use it to investigate block-wide patterns or detect anomalies. This method provides a comprehensive overview of how a block's transactions interact with the blockchain, which is crucial for understanding its overall effects and ensuring its correctness.

Try the trace_block RPC method yourself

Click Try It! to start a request and see the response here!