Effective Spread
Effective spread is an execution-cost metric: 2 × |execution price − midquote|, showing how far your fill is from the market midpoint.
Definition
Effective spread measures the real trading cost implied by your execution price relative to the market midpoint at the time you traded.
Formula: ES = 2 × |Pexec - M|
• Pexec is your execution price (use VWAP if you had multiple fills).
• M is the midquote at the time of the trade, M = (best bid + best ask) / 2.
Why it matters
Quoted spreads can look small, but your actual fill can be worse due to partial fills, thin depth, or price impact. Effective spread captures what you really paid versus the midpoint.
How to compute it (order book)
1. Record best bid and best ask at the moment you submitted the trade.
2. Compute the midquote: M = (bid + ask) / 2.
3. Compute your execution price Pexec (VWAP across fills).
4. Compute ES = 2 × |Pexec - M|.
Interpretation
• If you buy at the ask (or sell at the bid), ES equals the quoted spread (ask - bid).
• If you get price improvement (fill inside the spread), ES is smaller than the quoted spread.
• Larger ES often indicates thinner liquidity, worse timing, or larger order size relative to depth.
Common pitfalls
Wrong timestamp: Bid and ask must match the moment of your trade, not a later snapshot.
Using last trade price: ES is defined against midquote, not last price.
Ignoring multiple fills: Use VWAP, not a simple average.
Mixing in fees: Keep ES as a pure microstructure metric and add fees separately as all in cost.
AMM note
In AMMs there is no bid and ask. A common analog uses the spot price before the trade as the reference (P0) and compares it to your average execution price.