Skip to content

EMA Trend with Chandelier Exit

What it does: Enters on an average crossover and rides the trend with a volatility-based trailing exit. This buys when the 20-candle average crosses above the 50-candle average.

Style: Trend · Difficulty: Intermediate · Risk: medium · Ready: 2 of 2 variants

When people use it: It tends to work in clear trends, where the trailing line lets winners run.

Where it struggles: It struggles in sideways markets, where the averages cross back and forth. Sudden spikes can trigger the exit early.

Markets it was written for: BTC, ETH, majors. Timeframes: 4h (1h-1d).

Open it in the Strategy Library (on the Strategies page), pick a variant, adjust the settings and press Add to my strategies. It becomes your own strategy: edit, backtest or trade it like any other.

Long

Enters on an average crossover and rides the trend with a volatility-based trailing exit.

Labels: Trend Following, Long, Spot, Intermediate, Medium

  • Direction: Buy (long) · Market: spot
  • Trigger: On candle close · Main timeframe: Auto (4h)

Entry

  • IF EMA(20) crosses above EMA(50) (4h)

Exit: Indicator-Based Exit

  • IF Price crosses below CE(22,22,22,3) Long stop 1 bar ago (4h)
  • Loss controls: Stop-loss % 8%

Settings

Setting Default Editable What changing it does
Lookback 22 Yes (sets 3 fields) How many candles the exit line looks back for the highest high (or lowest low) and the normal swing size. Shorter follows the price more tightly and exits sooner; longer gives the trend more room and exits later.
ATR multiple 3 Yes How far the exit line sits from the recent high (or low, for the short), measured in normal price swings (ATR). Lower exits sooner and keeps more of a gain, but gets shaken out by normal swings; higher stays in longer but gives back more before exiting.

How it works (as shown in the app)

  • This buys when the 20-candle average crosses above the 50-candle average.
  • It sells when a candle closes below the Chandelier Exit: a line set a few times the normal price swing (ATR) below the highest high of the last 22 candles. As the price rises, the line rises with it.
  • A % stop-loss is also set as a safety net.
  • It tends to work in clear trends, where the trailing line lets winners run.
  • It struggles in sideways markets, where the averages cross back and forth. Sudden spikes can trigger the exit early.
  • Built for 4-hour candles (1 hour to 1 day also work).
  • The exit line here is not locked in place: it can move down again if the market gets more volatile.

Short (perp)

Shorts on an average crossover and rides the downtrend with a volatility-based trailing exit.

Labels: Trend Following, Short, Futures, Medium, Backtest Only

  • Direction: Sell (short) · Market: swap
  • Trigger: On candle close · Main timeframe: Auto (4h)

Entry

  • IF EMA(20) crosses below EMA(50) (4h)

Exit: Indicator-Based Exit

  • IF Price crosses above CE(22,22,22,3) Short stop 1 bar ago (4h)
  • Loss controls: Stop-loss % 8%

Settings

Setting Default Editable What changing it does
Lookback 22 Yes (sets 3 fields) How many candles the exit line looks back for the highest high (or lowest low) and the normal swing size. Shorter follows the price more tightly and exits sooner; longer gives the trend more room and exits later.
ATR multiple 3 Yes How far the exit line sits from the recent high (or low, for the short), measured in normal price swings (ATR). Lower exits sooner and keeps more of a gain, but gets shaken out by normal swings; higher stays in longer but gives back more before exiting.

How it works (as shown in the app)

  • This shorts when the 20-candle average crosses below the 50-candle average.
  • It buys back when a candle closes above the Chandelier Exit for shorts: a line set a few times the normal price swing (ATR) above the lowest low of the last 22 candles. As the price falls, the line falls with it.
  • A % stop-loss is also set as a safety net.
  • It tends to work in clear downtrends, where the trailing line lets the short run.
  • It struggles in sideways markets, where the averages cross back and forth. Sudden upward spikes can trigger the exit early.
  • Built for 4-hour candles (1 hour to 1 day also work).
  • The exit line here is not locked in place: it can move down again if the market gets more volatile.
  • Shorting means you profit if the price falls and lose if it rises.
  • Suggested leverage is at most 3x. On isolated margin, at 3x the exchange closes the position (liquidation) if the price moves about 33% against you, and you lose the margin you put into it. Keep your stop well inside that.
  • For now this version runs in backtests only; paper and live futures trading are coming later.

Warnings

  • "Backtest only for now: paper and live trading of shorts are coming later.": shown on short variants. They need perpetual or futures pairs.
  • Some variants suggest leverage. On isolated margin a liquidation loses the margin in that position; keep any stop well inside the liquidation distance (the Trade Builder warns you when it isn't).
  • Once added, the strategy's conditions get the usual condition checks. Messages show under each condition on the entry / exit conditions screen; setting errors start with the indicator's short name (for example "MACD: Fast must be between 1 and 1000") and block saving, while the other warnings never block saving and repeat in the strategy's Entry or Exit section. See the indicator pages below for each one.
  • "You already have this strategy with these settings (…). Change a setting to add another copy.": shown on the variant's page in the Strategy Library when you already added this variant with the same settings.

Good to know

  • After you add it, the strategy keeps the library's trigger and an Auto main timeframe; you can change both in the builder. Nothing links it back to the library, except that the builder still shows the library's explanations in the info bubbles.
  • Changing a setting before adding it also changes the saved name, so you can tell copies apart.
  • Past results don't predict future ones. Try it in a backtest and on paper before using real money.
  • Indicators used: CE, EMA.