> ## Documentation Index
> Fetch the complete documentation index at: https://docs.chainstack.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Debug & Trace | Polygon

> Polygon debug and trace API methods for inspecting smart contract execution, analyzing gas usage, and tracing transactions on Chainstack nodes.

Developers can access the debug and trace tools with the following methods:

<CardGroup>
  <Card title="debug_traceBlockByHash" href="/reference/polygon-traceblockbyhash" icon="angle-right" iconType="solid" horizontal />

  <Card title="debug_traceBlockByNumber" href="/reference/polygon-traceblockbynumber" icon="angle-right" iconType="solid" horizontal />

  <Card title="debug_traceTransaction" href="/reference/polygon-tracetransaction" icon="angle-right" iconType="solid" horizontal />

  <Card title="debug_traceCall" href="/reference/polygon-tracecall" icon="angle-right" iconType="solid" horizontal />

  <Card title="trace_transaction" href="/reference/polygon-trace_transaction" icon="angle-right" iconType="solid" horizontal />

  <Card title="trace_block" href="/reference/polygon-trace_block" icon="angle-right" iconType="solid" horizontal />
</CardGroup>

## Pre-built native tracers

<Info>
  ### Custom JavaScript tracers need a dedicated node

  The tracers listed below are native (built-in) tracers—you select one by name. Custom JavaScript tracers, where you pass raw JavaScript as the `tracer`, are available as customized solutions on the [Enterprise plan](https://chainstack.com/pricing/) on [dedicated nodes](/docs/dedicated-node).
</Info>

Developers can customize the type of tracing using various debug and trace methods, and there are numerous pre-built tracers available to choose from. Further is a list of the pre-built tracers that can be utilized.

### `4byteTracer`

This tracer looks for function signatures that are 4 bytes long during contract execution and gathers information about the method identifiers and the size of the provided data. This information can be helpful in matching a signature against the data size.

### `callTracer`

This tracer extracts information about all internal calls made by a transaction, providing visibility into how contracts interact with each other.

### `prestateTracer`

This tracer returns sufficient information about an account to create a local execution of the transaction. This procedure runs the given transaction again and monitors every aspect of the state that is modified or accessed during execution.

### `noopTracer`

This tracer does nothing but respond with a blank object. This a no operations tracer for testing setup.
