TradeLabs AILearn

IOC and FOK Orders

Immediate or cancel and fill or kill orders must trade at once or be cancelled. Learn how they differ, when traders use them and how partial fills are handled.

Intermediate3 min readUpdated 3 Oct 2026
Markdown
Lesson 9 of 38

Immediate or cancel (IOC) and fill or kill (FOK) are time in force instructions for orders that must trade right now or not at all. Neither type ever rests in the order book. They are used when a trader wants to take whatever liquidity is available at acceptable prices without leaving a visible order behind.

Immediate or cancel (IOC)#

An IOC order fills as much as possible immediately, at your limit price or better, and cancels any remainder.

Fill or kill (FOK)#

A FOK order must fill completely and immediately, or it is cancelled entirely.

Side by side#

IOCFOKNormal limit (day or GTC)
Must trade immediatelyYes, whatever it canYes, all of itNo
Partial fillsAllowedNot allowedAllowed
RemainderCancelledWhole order cancelledRests in the book
Visible in the bookNeverNeverYes

Why traders use them#

  • Avoid leaving information in the book. A large resting order can signal your intentions to others. IOC orders take liquidity without showing your hand.
  • Avoid unwanted fills later. If you only want to trade at current prices, a resting order could fill after conditions change.
  • All or nothing needs. An arbitrage or hedging trade may only make sense if the full size fills at once; a partial fill would leave an unhedged position. FOK protects against that.
  • Sweeping multiple venues. Algorithms often send IOC orders to several venues at once to collect available liquidity quickly. See Order Routing and Smart Order Routing.

IOC, FOK and market orders#

An IOC order with a limit set beyond the current price behaves much like a market order with protection: it takes the liquidity available up to your limit and never chases further. Many algorithmic and professional traders use limit IOC orders instead of market orders for this reason.

An all or none (AON) order also requires a complete fill, but unlike FOK it does not have to fill immediately. It can wait in the book until enough size is available. See All or None Orders.

Where you will see them#

  • Crypto exchanges: IOC and FOK are standard options on most order tickets.
  • Professional stock and futures platforms: available on most direct access platforms.
  • Retail stock apps: often not offered, or offered only on advanced tickets.

Common mistakes#

  • Expecting an IOC to rest. If nothing fills, it is simply gone; check your fills.
  • Using FOK in thin markets, where full size is rarely available at once, leading to repeated cancellations.
  • Forgetting partial fills from IOC orders when calculating position size and stops.

A related instruction, all or none, requires the full quantity to fill but does not require it to happen immediately; see All or None Orders.

Frequently asked questions#

What is the difference between IOC and FOK?#

Both must trade immediately. IOC accepts a partial fill and cancels the rest; FOK must fill entirely or nothing happens.

Can an IOC order be a market order?#

Some venues allow market IOC orders, but limit IOC orders are more common because they cap the price.

When should I use fill or kill?#

When a partial fill would be worse than no fill, such as in a hedge or arbitrage that only works at full size.

Sources#

Check your understanding

3 quick questions on this lesson. Get them all right to finish it.

Turn on JavaScript to take the quiz.

Finished this lesson?Sign in to save your progress across devices.
Next lessonAll or None OrdersAn all or none order must fill completely or not at all, but can wait to do so. Learn how AON orders work, why they often fill later and when they make sense.

Mentioned in