trace_replayTransaction | Base

Base API method trace_replayTransaction replays a single transaction using the trace module, returning detailed trace data about its execution. This method is crucial for developers, auditors, and analysts who need to understand the precise execution flow of a transaction, including calls made to other contracts, state changes, and the execution outcome.


  • transactionHash — The hash of the transaction you want to replay, specified as a hexadecimal string.
  • traceTypes — An array of strings specifying the types of traces to return. Common trace types include "vmTrace", "trace", and "stateDiff".


  • result — The trace data for the specified transaction. Depending on the traceTypes requested, this may include a detailed execution trace (vmTrace), a step-by-step list of executed operations (trace), or a summary of state changes (stateDiff).

Use case

The trace_replayTransaction method is invaluable for a detailed analysis of individual transactions. It can be used by developers to debug smart contract interactions, by auditors to verify transaction integrity and security, and by analysts to understand the effects of a transaction on the blockchain state. This method provides a deep dive into the transaction's execution, offering insights that are not readily available through standard transaction receipts.

Try the trace_replayTransaction RPC method yourself

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