Order Matching
- Category
- Trading Fundamentals
- Level
- Professional
Simple definition
How a venue decides which two orders trade when they meet. The usual rule is best price first and, among equal prices, whoever arrived first.
Professional definition
The engine's rule for pairing an incoming order with resting ones. Price-time priority is the default: a better price always executes before a worse one, and equal prices execute in order of arrival. Some markets allocate pro rata by size instead, and some blend the two.
Technical definition
A deterministic allocation procedure applied to every incoming order. Under price-time priority the book is a set of first-in-first-out queues, one per price level, consumed from the best price outward. Under pro-rata allocation the resting orders at the matched level share the incoming quantity in proportion to size, which removes much of the value of speed and rewards size instead; hybrids award a share to the first order and allocate the remainder pro rata. The rule is published per contract and changes optimal order placement.
Academic definition
The deterministic set of precedence and allocation rules by which an exchange pairs incoming orders with resting orders and distributes executed quantity among them.
Mechanism
Priority rules are incentives. Time priority pays for being early, so it produces a latency race and a deep book full of fast cancellations. Pro-rata pays for being large, so it produces oversized resting quantity that is not all intended to trade. The matching rule therefore shapes the book it appears to merely measure.
In practice
- Who uses it
- Anyone placing resting orders, latency-sensitive desks, and strategy designers choosing between competing on size and competing on speed.
- Why it matters
- It determines whether queue position or quantity is the thing worth paying for, which decides how a passive strategy has to be built.
- Limitations
- Rules are set per contract and per venue. Hybrid schemes with top-order priority or minimum allocations are common, so read the contract specification.
Common mistakes
- Assuming every market uses price-time priority.
- Posting small size in a pro-rata market and expecting a fill.
- Ignoring the published tie-break and rounding rules.
Examples
In a price-time market, being first in the queue at the best bid is worth real money, and desks spend on latency to get there. In a pro-rata market the same spend buys little, because allocation follows size.
An incoming order for 100 meets resting quantities of 300, 150 and 50 at the matched level. Pro rata gives 60, 30 and 10. Under price-time priority the first order alone would have taken all 100.
- incoming quantity Q = 100 at one price level
- resting quantities 300, 150, 50 (total 500)
- pure pro-rata allocation, no minimum allocation, no rounding
- share of first = 100 x 300 / 500 = 60
- share of second = 100 x 150 / 500 = 30
- share of third = 100 x 50 / 500 = 10
- check: 60 + 30 + 10 = 100
Real venues round allocations to the lot step and distribute leftovers by a published tie-break, so exact proportionality is rare.
Mathematical foundation
Variables
| a_i | Quantity allocated to resting order i | lots or units |
| Q | Incoming quantity to be allocated at that price level | lots or units |
| q_i | Resting quantity of order i at that level | lots or units |
| \sum_j q_j | Total resting quantity at that level | lots or units |
Procedure
Sum the resting quantity at the matched price level. Divide each order's resting quantity by that total to get its share, multiply by the incoming quantity, then apply the venue's rounding and leftover rules to reach whole tradable increments.
Worked example
- Q = 100
- q = (300, 150, 50), total 500
- 300 / 500 = 0.60 so a_1 = 60
- 150 / 500 = 0.30 so a_2 = 30
- 50 / 500 = 0.10 so a_3 = 10
Interpretation
The output is how much of an incoming order each resting participant receives when allocation follows size. It says nothing about who arrived first, which is precisely the information price-time priority uses instead.
Assumptions
- Allocations are rounded to the venue's lot step and leftovers are distributed by a published tie-break, so realised shares are rarely exactly proportional.
- Under price-time priority no such formula applies at all: allocation is sequential by queue position.
- Many venues apply a minimum allocation or a top-order priority before the pro-rata step, which changes the result materially for small orders.
- The formula describes allocation at a single price level, not the walk across levels that a large order performs.
- Matching rules differ per contract even on the same venue and are revised, so the applicable rule must be read from the contract specification.
Related terminology
- related
- Order Book Limit Order Book Dynamics Limit Order Market Order Maker and Taker Partial Fill Tick Size Lot Size Latency High-Frequency Trading
Order Book
The order book is the state: what is resting and where. Order matching is the rule that turns that state into trades, and two venues with identical books can allocate the same incoming order differently.
Sources
CME Group · matching algorithms and order allocation
https://www.cmegroup.com/content/dam/cmegroup/education/files/a-traders-guide-to-futures.pdf URL verified
Editorial status
Flagged by the editor as uncertain on a linguistic, mathematical or regulatory point.
