# Average True Range (ATR)

> Average True Range: a Wilder-smoothed average of each candle's true range, measuring volatility in price units.

Updated: 2026-10-25T01:30:08.000Z · https://chartrider.com/docs/indicators/atr/

## What you see
A line in its own pane, scaled to the lowest and highest ATR of the visible candles. The value is in the market's price units.

## How it is calculated
With N = Period:
1. True range of a candle: the largest of `high − low`, `|high − previous close|` and `|low − previous close|`. This way gaps between candles count as well.
2. The first ATR is the simple average of the first N true ranges, starting with the second loaded candle.
3. After that, Wilder smoothing: `ATR = (previous ATR × (N − 1) + true range) / N`.

## How to read it
- A high ATR means wide candles and fast moves, a low ATR a quiet market. The ATR says nothing about direction.
- A rising ATR during a breakout confirms participation; a long stretch of falling ATR (contraction) often comes before a breakout.
- The ATR is commonly used to size stops and targets, e.g. a stop 1.5 × ATR away, so the distance adapts to current volatility.
- The value is in price units and grows with the price level. To compare markets or long periods, use [ATR Moving](https://chartrider.com/docs/indicators/atr-moving/), which works in percent of price and normalises over a window.

## Using it in strategies
Output: `value` (price units). In the [Trade Setup](https://chartrider.com/docs/strategies/trade-setup/), "Range" or "Compare" restricts trading to a volatility band; the right thresholds depend on market and timeframe. In [WickScript](https://chartrider.com/docs/wickscript/) use the built-in `atr(length)` (Wilder), e.g. `close - 2 * atr(14)` for a stop level, and the series `truerange` for the true range of a single candle. You can also load this indicator with `use indicator "ATR" with period 14 as a` and read `a.value`.

## Settings

Open the settings with the slider icon next to the indicator (Indicators, `F3`). Numeric settings can be swept as Step 1 / Step 2 parameters when you run a strategy.

### Inputs

| Setting | Type | Default | Description |
|---|---|---|---|
| Period | Number | `14` | Number of true ranges in the Wilder average (N). (min 1) |
| Height | Number | `30` | Height of the pane in pixels. (min 30) |

### Styles

| Setting | Type | Default | Description |
|---|---|---|---|
| Line Color | Color | `#9E0000` |  |

## Outputs

These values can be used in Trade Setup triggers, filters and exits (see [Trade Setup](https://chartrider.com/docs/strategies/trade-setup/)) and in WickScript.

| Output | In WickScript | Description |
|---|---|---|
| value | `value` |  |

## Use in WickScript

`use indicator` creates this indicator inside a script, with settings by their ID. Each output is a field of the name after `as`. See [WickScript indicators](https://chartrider.com/docs/wickscript/indicators/).

```wickscript
wickscript 1
indicator "Average True Range (ATR) from the list" in pane
use indicator "ATR" with period 14 as myAtr
show myAtr.value as line "value"
```
