---
hide_title: false
hide_table_of_contents: false
pagination_next: null
pagination_prev: null
---

# console.trace()

The **`console.trace()`** method outputs a stack trace to the console.

## Syntax

```js
trace()
trace(object1, /* …, */ objectN)
```

### Parameters

- `objects` __optional__
  - : Zero or more objects to be output to console along with the trace. These are
    assembled and formatted the same way they would be if passed to the `console.log()` method.

### Return value

`undefined`.
