Stops & exits

Custom exit conditions

Use any condition type as an exit signal. RSI > 80 fires a close.

1 min readUpdated Jun 19, 2026

The exit_rules.conditions list accepts the same conditions you'd put in entry rules. Any fire = close the position. Use this for non-stop, non-target exits like "RSI hit 80, take the profit before the stop trails through."

Shape

"exit_rules": {
  "conditions": [
    { "type": "comparison", "indicator": "rsi", "operator": ">", "value": 80 }
  ]
}

Interaction with native SL/TP

Custom exit conditions emit a signal exit reason. When an entry has already attached native SL/TP to the exchange, the engine suppresses interpreter stop and target signals to avoid fighting the native fills. Custom signal exits still fire - they're in a different category.

Usage

  • RSI extreme exit: cap a trend trade when momentum gets parabolic.
  • Time-based exit: combine with in_session to close before a session boundary.
  • Indicator divergence detection via custom conditions.

Pitfalls

  • Multiple custom exits OR each other. Any single fire closes the position.
  • They don't override stops or targets that have already filled
    • by then the position is already closed.
Custom exit conditions | Help Center | LucraX · LucraX