Order stateIntermediate

Partial Fills

A partial fill occurs when only part of an order's quantity is executed and the remainder either continues to rest, is cancelled, or must be actively managed, leaving the order in an intermediate filled-but-incomplete state.

Quick Answer

A partial fill leaves your order half-done: some quantity trades and the rest rests, is re-priced, or is cancelled. Your code must track filled quantity and average price, not assume all-or-nothing. Ignoring partials is a common bug, because a system that believes it is fully in when only part filled will size and hedge the next trade wrongly.

Definition: Partial Fills

Partial Fills is an order state in which only part of the quantity executes, leaving a residual that must be rested, re-priced, or cancelled.

Key takeaways: Partial Fills

  • A partial fill executes only part of an order, leaving a residual that must be explicitly managed.
  • Orders are stateful — track filled quantity, average price and remaining quantity, not just done-or-not.
  • Apply execution reports idempotently and reconcile against the broker's authoritative position after any disconnect.
  • Size stops, targets and risk from the true filled quantity, never the intended quantity.

Partial Fills at a glance

Partial Fills — key facts at a glance, Indian algorithmic-trading context.
ClassOrder state
MeaningOnly part of the quantity executed
ResidualRests, is re-priced, or is cancelled
Must trackFilled quantity and average price
Failure modeAssuming all-or-nothing → wrong next size
Common inLarge orders and thin books

Partial Fills in simple words

A partial fill is when you ask to trade 10 lots but only 4 go through and 6 are still pending. This happens whenever the opposite side of the book does not have enough quantity at your price. The tricky part is not the fill itself but the bookkeeping: your system must know it now holds 4 lots, still has 6 working, and must decide what to do with that leftover before it double-counts or over-trades.

What Partial Fills is for

Handling partial fills correctly is what separates a toy script from a robust execution engine — it forces explicit order-state tracking so that position, risk and remaining quantity always reconcile with reality.

Partial Fills — professional explanation

Why partial fills happen

A partial fill arises whenever the liquidity available at your acceptable price is smaller than your order. A large limit order may fill against the depth at its level and rest for the balance; a marketable order set with an IOC validity fills what it can immediately and cancels the rest; a big market order sweeps several levels and, if it exhausts the book within a price band, may fill partially and stop. In F&O, iceberg-style or simply large institutional orders routinely fill in pieces over many trades. Partial fills are the normal case for any order that is large relative to instantaneous depth.

The order lifecycle and its states

An order is not binary. It moves through states: submitted, acknowledged, open (working), partially filled, filled, cancelled, or rejected. A partially filled order is simultaneously 'filled for X' and 'open for the remainder'. A correct execution engine models this explicitly, tracking filled quantity, average fill price, remaining quantity and last update time for every live order. Systems that treat an order as either done or not done break the moment a partial fill arrives, because their notion of position diverges from the exchange's.

Reconciliation and idempotency

Partial fills usually arrive as a stream of trade or execution messages, each reporting an incremental quantity, over a broker WebSocket or postback. The engine must apply these idempotently — processing the same execution report twice must not double-count the position — and must reconcile its internal position against the broker's reported position periodically. Fills can also arrive out of order or be missed during a disconnect, so a robust system reconciles on reconnect by fetching the authoritative order and position state rather than trusting only the event stream.

Deciding what to do with the residual

The unfilled remainder demands a decision that belongs to strategy and execution logic, not chance. Options include: leave it resting (patient, risks non-completion), re-price it more aggressively (chase, risks impact), cancel it (accept a smaller position), or convert to a market order (guarantee completion, pay slippage). The right choice depends on urgency and why you were trading. A hedge that must be complete cannot be left half-on; a patient accumulation can wait. Encoding this decision explicitly is a core execution-engine responsibility.

Risk and sizing implications

Partial fills interact directly with risk control. If your position sizing assumed a full 10-lot fill but only 4 filled, your actual risk, exposure and hedge ratio are all different from plan, and any stop or target sized to 10 lots is now mismatched. Worse, if you naively resend the 'unfilled' quantity without accounting for what already filled, you can end up over-positioned. Every downstream risk calculation must read from the true filled quantity, updated continuously, not from the order you intended.

Backtesting partial fills

Most simple backtests assume every order fills completely and instantly, which quietly overstates strategies that trade size in thin instruments. A more realistic simulation caps the fill at the available depth or a fraction of the bar's volume (a participation limit), producing partial fills and forcing the backtested strategy to handle residuals just as the live one must. Ignoring this is a form of optimism closely related to ignoring liquidity and impact: it credits the strategy with size it could never actually get filled.

How Partial Fills looks visually

Order LifecycleCreatedValidatedSentAcknowledgedPartiallyFilledFilledRejectedCancelledrejectcancel
An order transitioning through partially-filled states, with residual quantity resting or being cancelled.

Worked example: Partial Fills

Illustrative example (Indian market)

Your system wants to buy 10 lots of a Bank Nifty option (lot 30, so 300 units) with a limit at a premium of 250. At that price only 120 units (4 lots) are resting, so you fill 4 lots at 250 and 6 lots (180 units) remain working. Your engine must now record: position +4 lots, average price 250, remaining order 6 lots open. Suppose you decide the entry is urgent and re-price the residual to 252 as a marketable limit; it fills the remaining 6 lots at an average 251.5. Your true blended entry is (4×250 + 6×251.5)/10 = 250.9, not the 250 you first saw. If instead you had cancelled the residual, your position is only 4 lots and any stop sized for 10 lots is now three-and-a-half times too large relative to the real position.

On NSE F&O, large orders are commonly split by the exchange into multiple trades reported individually, and brokers relay these as separate execution messages over their WebSocket or postback. An algo that assumes one order equals one trade message will mis-track positions on any sizeable F&O order, which is why production Indian algos reconcile against the broker's positions endpoint rather than counting messages.

Limitations of Partial Fills

  • Leftover residual quantity leaves the intended position incomplete unless actively managed
  • Requires explicit, stateful order tracking that simple scripts usually lack
  • Execution messages can duplicate, arrive out of order, or be missed on a disconnect
  • A mismatch between intended and filled size breaks stops, targets and hedge ratios
  • Chasing the residual aggressively can cost extra slippage; leaving it risks non-completion

Why Partial Fills matters in practice

  • Correct partial-fill handling is the dividing line between a robust execution engine and a fragile script
  • Position and risk reconciliation depends entirely on tracking true filled quantity, not intended quantity

How professionals treat Partial Fills

Institutional execution systems are built around the reality that orders fill in pieces. A parent order is split into child orders, each of which may fill partially, and the order management system aggregates fills into a running position with an average price, reconciling continuously against the broker and exchange. Execution reports are applied idempotently and keyed by a unique execution id; on reconnect the system re-fetches authoritative state rather than replaying a possibly incomplete stream. The residual-handling policy — chase, rest, or cancel — is an explicit, configurable part of each execution algorithm, tuned to the order's urgency rather than left to accident.

Common mistakes with Partial Fills

  • Treating an order as all-or-nothing, so a partial fill desynchronises the system's position from the exchange's
  • Resending the full quantity after a partial fill and ending up over-positioned
  • Double-counting a fill by processing the same execution report twice (no idempotency)
  • Sizing stops and targets to the intended quantity instead of the actual filled quantity
  • Trusting only the event stream and never reconciling against the broker's authoritative position after a disconnect
  • Backtesting with guaranteed full instant fills, hiding the residual-management problem entirely

Partial Fills: frequently asked questions

What is a partial fill?

A partial fill is when only part of an order's quantity executes and the rest remains unfilled. The order enters a partially-filled state, holding a real position for the filled portion while the remainder continues to work, is cancelled, or must be actively managed.

Why do partial fills happen?

They happen when the liquidity available at your acceptable price is smaller than your order size. The order fills against whatever depth exists and then either rests for the balance, cancels the balance (if IOC), or stops after sweeping the book within its price band.

Why is order state management important for partial fills?

Because a partially filled order is both filled and open at once, a system must track filled quantity, average price and remaining quantity precisely. Without that state, its idea of the position diverges from the exchange's, breaking risk controls and potentially causing over-trading.

How should I handle the residual after a partial fill?

It depends on urgency. You can leave it resting to complete patiently, re-price it more aggressively to chase, cancel it and accept a smaller position, or convert it to a market order to guarantee completion at the cost of slippage. Encode this as an explicit policy, not an afterthought.

What does idempotent processing mean for fills?

It means applying each execution report exactly once even if it is delivered more than once. Fill messages can be duplicated or replayed, so keying them by a unique execution id and ignoring repeats prevents double-counting the position.

Are partial fills more common in options?

Yes, particularly in less liquid strikes where depth at any price is thin, so a sizeable order fills in pieces. On NSE F&O even a single order is often reported as multiple trades, so partial-fill handling is essential for options algos.

Sources & references

  • Robert Kissell, “The Science of Algorithmic Trading and Portfolio Management”, Academic Press (Elsevier), 2013
  • Irene Aldridge, “High-Frequency Trading: A Practical Guide to Algorithmic Strategies and Trading Systems”, 2nd ed., Wiley, 2013

Published 10 July 2026. Educational content only — not investment advice. Markets and rules change; verify current conventions with SEBI, NSE/BSE and your broker.

Educational content only — not investment advice. Examples use illustrative numbers and simplified models. Algorithmic trading and derivatives involve substantial risk. See our Risk Disclosure and SEBI Disclaimer.