What is GTC/FOK/IOC Orders
What is Time in Force?
Time in Force (TIF) defines how a limit order should be handled if it is not immediately and fully filled.
In perpetual futures trading, in addition to setting the order price and quantity, users may also need to select the Time in Force for their order. Different TIF options determine whether the order remains on the book, gets canceled immediately, or allows partial fills.
The common Time in Force options are: GTC, FOK, and IOC.
What is a GTC Order?
GTC stands for Good Till Canceled.
After a GTC order is submitted, any unfilled portion remains on the order book until it is fully filled, manually canceled by the user, or canceled by the system according to platform rules.
GTC is the most common default Time in Force setting for limit orders.
📚Example
The current XAUUSD perpetual contract price is 3,300 USD.
A user submits a buy limit order:
Limit Price: 3,280 USD
Quantity: 10 XAU
Time in Force: GTC
If the market price has not yet reached 3,280 USD, the order will remain on the order book.
If the market price subsequently falls to 3,280 USD and there are sufficient matching orders, the order may be filled.
If the user no longer wishes to wait, they can manually cancel the order.
When to Use GTC?
GTC is ideal when users want to be filled at a specific price and are willing to wait for the market to reach that level.
For example, a user who wants to open a position in XAUUSD only after it pulls back to a target price can place a GTC limit order and wait.
What is a FOK Order?
FOK stands for Fill or Kill.
When a FOK order is submitted, the system checks whether the order can be immediately filled in its entirety at the specified price.
If it can be fully filled, the order executes immediately in full.
If it cannot be fully filled, the order is immediately canceled — no partial fill is allowed, and it will not remain on the order book.
📚Example
The current XAUUSD perpetual contract price is 3,300 USD.
A user submits a buy limit order:
Limit Price: 3,305 USD
Quantity: 10 XAU
Time in Force: FOK
If the current order book has sufficient volume at 3,305 USD or better to fill all 10 XAU, the order will be immediately filled in full.
If only 6 XAU are available at 3,305 USD or better, the order will not partially fill — it will be canceled entirely.
When to Use FOK
FOK is appropriate when users require the entire order to be filled at once and will not accept a partial fill or a resting order.
For example, a user who wants to open or close a full position in one go at a specific price level — and prefers no fill over a partial fill — should use FOK.
What is an IOC Order?
IOC stands for Immediate or Cancel.
When an IOC order is submitted, the system immediately attempts to match it at the specified price.
Any portion that can be immediately filled is executed; the remaining unfilled portion is canceled.
IOC allows partial fills, but the unfilled portion will not remain on the order book.
📚Example
The current XAUUSD perpetual contract price is 3,300 USD.
A user submits a buy limit order:
Limit Price: 3,305 USD
Quantity: 10 XAU
Time in Force: IOC
If only 6 XAU are available at 3,305 USD or better, the order will immediately fill 6 XAU and the remaining 4 XAU will be canceled.
If no volume is available at 3,305 USD or better, the entire order will be canceled.
When to Use IOC
IOC is suitable when users want to fill as much of the order as possible immediately but do not want any unfilled portion to remain on the order book.
For example, a user who wants to fill as much of their order as the current order book allows — without leaving a resting order — should use IOC.
Differences Between GTC, FOK, and IOC
The key difference between GTC, FOK, and IOC lies in how the system handles the unfilled portion of an order.
GTC allows resting orders. After submission, unfilled portions remain on the order book until filled or canceled.
FOK does not allow partial fills or resting orders. The order must be filled in full immediately, or it is entirely canceled.
IOC allows partial fills but does not allow resting orders. After submission, the immediately fillable portion is executed and the remainder is canceled.
Time in Force | Partial Fill Allowed | Resting Order Allowed | Handling of Unfilled Portion | Use Case |
GTC | Yes | Yes | Remains on book until filled or canceled | Want to fill at target price; willing to wait |
FOK | No | No | Fully canceled if not completely fillable | Only accepts immediate full execution |
IOC | Yes | No | Fills what's available immediately; cancels the rest | Wants immediate fill; accepts partial execution |
What to Note When Using GTC, FOK, and IOC
1.GTC, FOK, and IOC are typically used with limit orders.
2.GTC orders may remain on the order book for an extended period. Users should monitor their open orders regularly.
3.FOK orders must be fully filled immediately; otherwise they are entirely canceled.
4.IOC orders allow partial fills, but the unfilled portion is immediately canceled.
5.FOK and IOC depend heavily on order book depth. If market liquidity is insufficient, orders may not be fully filled (or for FOK, may be entirely canceled).
6.When using FOK or IOC, users should verify that the specified price and quantity are reasonable.
Frequently Asked Questions
1. Does a GTC Order Stay Active Indefinitely?
A GTC order remains active until it is filled, canceled by the user, or canceled by the system.
Note that GTC orders may also be canceled by the system in cases such as contract suspension, position liquidation, system maintenance, risk control actions, price limit breaches, or other exceptional circumstances.
2. Why Was My FOK Order Immediately Canceled?
FOK orders require immediate, complete execution. If the current order book does not have sufficient volume at the specified price or better to fill the entire order, the system cancels it immediately.
For example, if a user submits a FOK buy order for 10 XAU but only 6 XAU are available, the entire order is canceled — it will not partially fill 6 XAU.
3. Why Was My IOC Order Only Partially Filled?
IOC orders allow partial fills. The system immediately matches whatever quantity is available and cancels the rest.
For example, if a user submits an IOC buy order for 10 XAU but only 6 XAU are available, 6 XAU are filled and the remaining 4 XAU are canceled.
4. What is the Difference Between FOK and IOC?
FOK requires the entire order to be filled immediately; otherwise the entire order is canceled. Partial fills are not accepted.
IOC allows partial immediate fills, but any unfilled portion is canceled.
In short: FOK is "all or nothing"; IOC is "fill what you can now, cancel the rest."
5. What is the Difference Between GTC and IOC?
With a GTC order, unfilled portions remain on the order book waiting for future execution.
With an IOC order, unfilled portions are immediately canceled and will not remain on the order book.
If users are willing to wait for their specified price, choose GTC.
If users only want to fill what's immediately available and do not want a resting order, choose IOC.
6. Do GTC, FOK, and IOC Affect the Execution Price?
GTC, FOK, and IOC primarily affect how an order is handled after submission — they do not directly change the specified limit price.
The actual execution price still depends on the limit price, market price, order book depth, and matching conditions. Buy orders are typically filled at or below the limit price; sell orders at or above.
7. Can Market Orders Use GTC, FOK, or IOC?
GTC, FOK, and IOC apply to limit orders. Market orders are designed to execute at the best available price as quickly as possible and do not require a Time in Force setting.