> **Can't find what you're looking for?** Use `search_docs` on the docs MCP server at `https://www.getfoundry.sh/api/mcp` to find what you need.
>
> **Have feedback?** Use `submit_feedback` on the same MCP server.

## `pauseTracing`

### Signature

```solidity
function pauseTracing() external view;
```

### Description

Pauses the collection of call traces. Calls made while tracing is paused still execute normally, but they are omitted from the trace output. Use it to skip setup or other noisy calls that are not useful for debugging, then call [`resumeTracing`](/reference/cheatcodes/resume-tracing) to start recording again.

Calling `pauseTracing` while tracing is already paused has no effect. The cheatcode takes effect whenever Forge collects traces, including for failing tests at `-vvv`.

### Examples

```solidity [test/PauseTracing.t.sol]
// [!include ~/snippets/projects/tracing/test/PauseTracing.t.sol]
```

```bash
$ forge test --root src/snippets/projects/tracing --match-contract PauseTracingTest -vvvv
```

The ten `increment` calls made while tracing is paused do not appear in the trace. The final `increment` and `number` calls do.

### Related Cheatcodes

* [`resumeTracing`](/reference/cheatcodes/resume-tracing) - Resumes the collection of call traces
* [`pauseGasMetering`](/reference/cheatcodes/pause-gas-metering) - Pauses gas metering
