What is OCO Order?
Reviewed by Karthikeyan Anbarasan (Founder, TradeLyser) · Updated 19 Oct 2026 · Editorial policy
An OCO solves a simple problem. Once you are in a trade you want two exits waiting: one above for the profit, one below for the loss. If both sit as separate orders, the first to fill leaves the other live, and a forgotten order can open an unwanted position. Linking them means the first fill closes the trade and the other leg disappears.
How an OCO order works
- Enter the position first, with your own order.
- Set the target leg above the current price for a long (below for a short), usually as a limit order.
- Set the stop leg below the current price for a long (above for a short), with a trigger and, if your broker asks for one, a limit price.
- When price reaches either trigger, that leg is sent to the exchange and the other leg is cancelled.
- Check after the fill that the remaining leg shows as cancelled and that your net position is zero.
OCO at Indian brokers
Indian brokers usually offer OCO as a two-leg GTT (good till triggered) order. The broker, not the exchange, watches the last traded price and sends a limit order when a leg is hit. That has two consequences: the order is not in the exchange book until it triggers, and a triggered leg can still miss if price moves past its limit. Validity periods and the segments covered differ by broker, so check your broker for whether OCO works on F&O as well as on delivery stocks.
OCO (two-leg GTT)
Bracket order
Cover order
Worked example: OCO on a swing trade
| Leg | Trigger | Limit | Result if filled (100 shares) |
|---|---|---|---|
| Target | ₹1,590 | ₹1,590 | +₹9,000 |
| Stop | ₹1,455 | ₹1,450 | −₹4,500 at the trigger, −₹5,000 at the worst limit |
Illustrative large-cap NSE stock bought at ₹1,500. The stop leg uses a ₹5 buffer between trigger and limit, so a quick drop through ₹1,455 still has room to fill. The cost of that room is ₹500 of extra loss in the worst case, which is the price of a higher chance of getting out. The target leg needs no buffer: if price jumps through ₹1,590, a sell limit at ₹1,590 fills at that price or better.
Logging it and avoiding the usual mistakes
- Record both legs at entry: target, stop trigger, stop limit and the planned R. The exit then tells you which leg won without guesswork.
- Tag manual overrides. If you move the target or close early, mark the trade “OCO overridden” so overrides can be reviewed as their own group.
- After 30 or more OCO trades, compare the share that hit the target with your breakeven win rate for that ratio, 33.3% at 1:2.
- Cancel the OCO whenever you exit by hand, add to the position or change quantity. A leg sized for the old quantity can over-sell, and a leg left live after a manual exit can trigger weeks later, selling shares you still hold in the demat account or opening a fresh short in F&O.
Reference guide
| Context | Value | Reading |
|---|---|---|
| OCO placed right after entry, both legs from the written plan | Plan enforced | Target and stop are fixed before emotions arrive; log both levels in the journal |
| Position exited by hand, OCO left live | Dangerous | A leg can still trigger later and sell other shares you hold or open a fresh position; cancel it |
| Stop leg with its limit equal to the trigger | May not fill | A fast fall or gap can skip the limit; set the limit a few ticks beyond the trigger |
Questions
What is an OCO order?
Two linked orders, usually a target and a stop-loss, where the fill of one cancels the other. It closes a trade at either level without leaving a stray order behind.
Is OCO available at Indian brokers?
Usually as a two-leg GTT order. Which segments it covers and how long it stays valid vary, so check your broker.
What is the difference between OCO and a bracket order?
An OCO only handles the exits of a position you already hold. A bracket order places the entry and both exits together, usually for intraday trades.
Does an OCO guarantee my stop-loss will fill?
No. When a leg triggers, it usually goes out as a limit order, which can miss in a fast move or a gap. A buffer between trigger and limit improves the chance of a fill.