Immediate or Cancel Order (IOC)
Category
Related Terms
See Also
Browse by Category
What Is an Immediate or Cancel Order?
An Immediate or Cancel (IOC) order is a time-in-force instruction that requires immediate execution of all or part of an order, with any unfilled portion automatically canceled.
An Immediate or Cancel (IOC) order is a specialized order type that prioritizes immediate execution while preventing any unfilled portion from remaining in the market. When you place an IOC order, the trading system attempts to fill as much of your order as possible right away. Any portion that cannot be executed immediately is automatically canceled, rather than sitting in the order book waiting for future execution. This mechanism provides traders with precise control over both timing and market exposure. This order type was developed to give traders precise control over execution timing and to prevent unwanted partial fills from lingering in the market. IOC orders are particularly valuable in fast-moving markets where prices can change rapidly, or for traders who want to ensure their orders don't execute at unfavorable prices later. High-frequency traders and algorithmic trading systems commonly use IOC orders for their speed and precision. IOC orders differ from standard market or limit orders by their strict time-in-force condition. While a regular order might wait minutes, hours, or days for execution, an IOC order lives for only a matter of seconds—typically the time it takes to check available liquidity and attempt execution. This makes IOC orders a tool for traders who prioritize execution certainty and timing over waiting for potentially better prices.
Key Takeaways
- IOC orders execute immediately or cancel, ensuring no lingering orders in the market
- They prevent partial fills from sitting in the order book when immediate execution is desired
- IOC orders are ideal for fast-moving markets or when timing is critical
- They provide control over execution but may result in missed opportunities if liquidity is insufficient
- Commonly used by algorithmic traders and scalpers who need immediate execution
How IOC Order Execution Works
When an IOC order reaches the market, the trading system immediately attempts to match it against available orders in the order book. The system checks for counterparties willing to trade at the specified price (for limit IOC orders) or at current market prices (for market IOC orders). Any portion that can be filled immediately gets executed, while the remainder is canceled without entering the order book. This happens automatically without any further action required from the trader. The execution process happens in microseconds on electronic exchanges. The order routing system follows a specific sequence: 1. Receives the IOC order with its time-in-force instruction 2. Immediately scans available liquidity at the specified price level 3. Executes the maximum possible quantity against standing orders 4. Cancels any unfilled balance instantly without adding it to the book This approach within the immediate timeframe ensures that IOC orders never contribute to market depth or remain visible to other traders. They exist purely for immediate execution attempts and disappear immediately after, leaving no trace in the order book. Different exchanges may have slight variations in IOC implementation, but the core principle remains the same across all major markets: immediate execution or immediate cancellation with no lingering exposure.
Step-by-Step Guide to Using IOC Orders
Determine if IOC is appropriate for your trading situation. IOC orders work best when you need immediate execution and cannot tolerate partial fills sitting in the market. Consider factors like market volatility, available liquidity, and your risk tolerance. Select your order parameters. For market IOC orders, specify the quantity you want to trade - the system will attempt to execute at the best available prices. For limit IOC orders, set both quantity and price limit to control maximum execution price. Submit the order with IOC time-in-force instruction through your trading platform. Most modern platforms have IOC as a checkbox or dropdown option in the order entry screen. Verify that your broker supports IOC orders and understand any associated fees. Monitor the execution results. IOC orders will either execute partially/fully immediately or be completely canceled. Check your order history to see what was filled and at what prices. If the order was canceled, reassess market conditions and decide on next steps. Use IOC orders strategically. They work well for scalping strategies, arbitrage opportunities, or when you want to test market liquidity without committing to a standing order.
Key Elements of IOC Orders
The defining characteristic of IOC orders is their immediate time-in-force condition. Unlike day orders that remain active until market close or GTC orders that persist indefinitely, IOC orders have a lifespan measured in seconds or less. This ensures they never contribute to market depth or become visible to other market participants. Execution priority depends on the order type combined with IOC. Market IOC orders have highest priority and will execute against any available liquidity. Limit IOC orders execute only at the specified price or better, providing price control while maintaining the immediate execution requirement. Partial fills are possible with IOC orders. If the market can absorb part of your order immediately but not all of it, you'll get a partial execution and the remainder cancels. This differs from Fill-or-Kill (FOK) orders, which cancel entirely if they can't execute fully. Exchange-specific rules may apply. Some exchanges allow IOC orders only during continuous trading hours, while others support them in pre-market or after-hours sessions. Understanding these nuances ensures proper order placement.
Important Considerations for IOC Orders
IOC orders require sufficient market liquidity for successful execution. In thin markets or during low volume periods, IOC orders may cancel entirely even if you'd accept execution at slightly worse prices. Consider market conditions before using IOC orders. Price control is limited with market IOC orders, which can execute at significantly different prices than expected if slippage occurs. Always use limit IOC orders when price precision matters. Be aware that in fast-moving markets, even limit orders may execute at prices worse than your limit if the market gaps. IOC orders may incur higher commission costs due to their specialized nature and the potential for multiple order submissions. Factor these costs into your trading strategy. Some exchanges charge premium fees for IOC orders compared to standard orders. Timing is critical with IOC orders. They work best in liquid markets during active trading hours. Using IOC orders during market open/close or news events may result in poor execution due to increased volatility and reduced liquidity.
Advantages and Disadvantages of IOC Orders
IOC orders provide precise control over execution timing, preventing unwanted partial fills from remaining in the market. Traders can attempt immediate execution without worrying about orders lingering and executing at unfavorable times. They enable efficient liquidity testing and support advanced trading strategies used by algorithmic traders and scalpers where timing is critical. However, IOC orders may miss execution opportunities if the market moves favorably after cancellation. They provide no price improvement potential, as they execute immediately at current prices or cancel. IOC orders can be costly in illiquid markets where orders cancel repeatedly, incurring multiple commissions without execution. They also require active market monitoring, making them unsuitable for traders who cannot watch markets continuously.
Real-World Example: Scalping Strategy
A scalper identifies a 2-cent price inefficiency in a liquid stock trading at $50. They want to buy 1,000 shares immediately if available at $49.98 or better.
Liquidity Dependency Warning
IOC orders depend entirely on immediate market liquidity. In thin or illiquid markets, orders may cancel completely even when you would accept execution. Always assess market depth before using IOC orders, and consider using regular orders during low liquidity periods. IOC orders are not suitable for illiquid securities or off-hours trading when liquidity is limited.
Other Time-in-Force Orders
IOC orders are part of a family of time-in-force instructions that control order duration and execution behavior. Fill-or-Kill (FOK) orders are similar but cancel entirely if they can't execute fully immediately. All-or-None (AON) orders require complete execution but may wait for counterparties. Good-Till-Canceled (GTC) orders remain active until filled or canceled, suitable for patient traders. Day orders expire at market close, providing intraday flexibility. Some exchanges offer extended hours orders that persist into pre-market or after-hours sessions. Modern trading platforms often combine time-in-force with other order conditions, creating sophisticated execution instructions. Understanding these options allows traders to precisely control their order behavior based on market conditions and trading objectives.
IOC vs. Other Order Types
Different order types offer varying levels of execution control and market exposure.
| Order Type | Execution Speed | Price Control | Market Exposure | Best For |
|---|---|---|---|---|
| IOC | Immediate | Variable (limit optional) | None after attempt | Scalping, arbitrage |
| Market | Immediate | None | High slippage risk | Urgent execution |
| Limit | Variable | Fixed maximum/minimum | Extended | Price precision |
| Stop | When triggered | Market after trigger | Until triggered | Breakout/crash protection |
| FOK | Immediate | Variable | None (all-or-nothing) | Complete fills only |
Tips for Using IOC Orders Effectively
Use IOC orders during high liquidity periods when immediate execution is likely. Combine with limit orders to maintain price control. Monitor order flow and adjust quantities based on available liquidity. Consider using IOC for testing market conditions before committing larger orders. Keep position sizes realistic for available liquidity. Use in conjunction with market data to time entries optimally.
Common Beginner Mistakes
Avoid these frequent errors when using IOC orders:
- Using IOC orders in illiquid markets where they frequently cancel without execution
- Submitting large IOC orders that exceed available immediate liquidity
- Forgetting that IOC orders provide no price protection on market orders
- Using IOC for long-term positions where immediate execution isn't necessary
- Not accounting for higher commission costs associated with frequent IOC usage
FAQs
If an IOC order cannot execute immediately, the entire unfilled portion is automatically canceled. Unlike regular orders that remain in the market waiting for execution, IOC orders disappear completely after the initial execution attempt. This ensures you never have lingering orders that might execute at unfavorable prices later. Partial fills are possible - any portion that can execute immediately will fill, while the rest cancels.
Use IOC orders when you need immediate execution and cannot tolerate having unfilled orders remain in the market. They are ideal for scalping strategies, arbitrage opportunities, fast-moving markets, or situations where timing is critical. IOC orders work best in liquid markets during active trading hours when sufficient liquidity exists for immediate execution. Avoid them in illiquid markets or when you can afford to wait for better prices.
IOC (Immediate or Cancel) and FOK (Fill or Kill) orders both require immediate execution, but differ in how they handle partial fills. IOC orders will execute any portion that can fill immediately and cancel the rest, allowing partial executions. FOK orders cancel entirely if they cannot execute the full order quantity immediately - they are truly all-or-nothing. IOC is more flexible for partial fills, while FOK ensures complete execution or no execution.
Yes, IOC orders can be either market orders or limit orders. A market IOC order attempts immediate execution at the best available prices, while a limit IOC order specifies a maximum buy price or minimum sell price. The IOC time-in-force applies to both - any unfilled portion cancels immediately regardless of whether it's a market or limit order. Limit IOC orders provide price protection while maintaining the immediate execution requirement.
IOC orders may incur higher commission costs than standard orders due to their specialized nature and the potential for multiple order submissions. Some exchanges charge premium fees for IOC orders, and the need to potentially resubmit orders can increase total commissions. However, the cost depends on your broker and exchange - some platforms offer IOC orders at standard rates. Factor these costs into your trading strategy, especially for frequent traders.
The Bottom Line
Immediate or Cancel orders provide traders with precise control over execution timing, ensuring that orders either execute immediately or disappear completely. This order type is invaluable for traders who prioritize timing and execution certainty over waiting for potentially better prices. While IOC orders can miss opportunities and may be costly in illiquid markets, they excel in fast-moving, liquid environments where immediate execution is essential. Understanding when and how to use IOC orders is crucial for traders employing scalping strategies, arbitrage, or any approach requiring immediate market access. Like any specialized tool, IOC orders work best when matched to appropriate market conditions and trading objectives.
Related Terms
More in Order Types
At a Glance
Key Takeaways
- IOC orders execute immediately or cancel, ensuring no lingering orders in the market
- They prevent partial fills from sitting in the order book when immediate execution is desired
- IOC orders are ideal for fast-moving markets or when timing is critical
- They provide control over execution but may result in missed opportunities if liquidity is insufficient