The bid-ask spread is the difference between the lowest price at which anyone will sell (ask) and the highest price at which anyone will buy (bid) at any given moment. It is the fundamental measure of market liquidity and the primary execution cost on every trade you take — whether or not your broker charges a commission.
Section 1: Core Mechanics
The bid-ask spread captures the transaction cost embedded in every market order execution. When you buy at market, you pay the ask. When you sell at market, you receive the bid. The spread is the immediate round-trip cost before any price movement — money transferred directly from active traders to liquidity providers.
Formula
Three spread measures serve different purposes:
Absolute Spread:
Relative Spread (in basis points):
Where .
Effective Spread (actual cost of a completed trade):
The effective spread measures what a trader actually paid vs. what they theoretically should have paid at the midpoint. It captures the cost of aggressive execution.
Inputs
- Best bid: Highest price any market participant will pay right now
- Best ask: Lowest price any market participant will accept right now
- Trade price: Where a completed transaction executed (for effective spread)
Parameters
| Parameter | Default | Range | Impact |
|---|---|---|---|
| Spread type | Absolute | Absolute / Relative / Effective | Relative allows cross-price comparison; effective captures real execution cost |
| Averaging window | 1m | Real-time to 1D | Averaged spread smooths momentary spikes; useful for daily liquidity scoring |
| Basis points vs. percent | Basis points | bps / % | Institutional standard is basis points (1 bps = 0.01%) |
Output and Visual Behavior
Spread is displayed as a live number in a platform's quote window or computed in custom code. On a time-series chart, spread plotted over time shows intraday liquidity cycles: tight near the open and close for large-caps, widening during midday lull, spiking dramatically around news events and earnings.
Section 2: Interpretation & Signals
Spread by Asset Class — Reference Ranges
| Asset | Typical Spread | Relative Cost | Liquidity Rating |
|---|---|---|---|
| S&P 500 large-caps (AAPL, SPY) | $0.01 (1 penny) | ~0.5 bps | Excellent |
| Mid-cap equities | $0.01–$0.05 | 2–10 bps | Good |
| Small-cap equities | $0.05–$0.50 | 20–200 bps | Fair to poor |
| Micro-cap / OTC | $0.50–$5.00+ | 500+ bps | Avoid for active trading |
| EUR/USD forex | 0.1–0.5 pips | ~0.5 bps | Excellent |
| Bitcoin (major exchanges) | $1–$10 | 1–5 bps | Good |
| Pre/post market equities | 5–10x normal | Highly variable | Trade with limit orders only |
When Spread Matters Most
Scalping: A scalper targeting a 10-cent profit on a stock with a 5-cent spread has already surrendered 50% of the target to execution cost. The trade must move 5 cents before breakeven.
High-frequency: Round-trip spread costs compound rapidly. 50 trades per day on 1,000 shares with a 2-cent spread = $1,000 in spread costs daily. Zero commission does not mean zero cost.
Pre-event trading: Spreads widen 2–10x before earnings releases and FOMC announcements as market makers hedge uncertainty. Entering a position 30 minutes before a news event means paying an inflated spread — and selling into an inflated spread if the move goes against you.
Using Spread as a Risk Signal
Persistently widening spread on a stock without a scheduled news event signals one of three things:
- Informed traders are taking positions — market makers widen spread to protect against adverse selection
- A large institutional order is working — market makers see unusual flow
- Liquidity is drying up — approaching a weekend, holiday, or illiquid period
Limit Orders vs. Market Orders — The Spread Decision
- Market order (taker): Execute immediately at ask (buy) or bid (sell). Pay full spread. Guaranteed fill, guaranteed cost.
- Limit order (maker): Provide liquidity at your specified price. If filled, you capture the spread — not pay it. No fill guarantee.
On most stocks with sub-3-cent spreads, limit orders at midpoint fill within 1–3 seconds during regular session hours. The fill rate is high enough that limit orders are almost always preferable to market orders for non-urgent execution.
Intraday Spread Pattern — Large-Cap US Equity (Typical Day)
Section 3: Pass vs. Live — Real-Time Reliability
Spread is purely real-time. Historical spread data is useful for backtesting execution costs and identifying liquidity regimes, but the spread you observe at entry time is the only relevant number for the current trade. Pre-event spreads can change within seconds of a news release — a 1-cent spread at 1:59 PM before a 2:00 PM FOMC announcement may widen to 20 cents in the seconds after the release.
Section 4: Practical Use Cases
Setup: Real-time spread monitor alongside 1m–5m price chart Signal: Trade only when spread is below 0.02% (2 bps) relative to price — this ensures spread cost is less than 20% of a typical scalp target Entry: Use limit orders at midpoint (bid + ask) / 2 — never market orders for scalp entries Exit: Limit order at target; market order only if stop hit (urgency justifies cost) Key rule: If spread widens above 0.05% during the trade, reduce size immediately — liquidity is deteriorating
Setup: Check daily average spread before adding a new position; track spread trend over 5 days Signal: Pre-event spread check — if spread is more than 2x the 5-day average, delay entry until after the event Entry: Limit orders at or below ask for longs — allow 30 seconds for fills before adjusting Exit: Limit orders; accept market order only at hard stop levels Key rule: For stocks under $20, relative spread > 0.3% is a deal-breaker for swing trades — too costly to overcome
Setup: Weekly average spread assessment for portfolio stocks Signal: Rising spread trend (week-over-week) in a position you hold signals deteriorating liquidity — review fundamentals Entry: Spread is less relevant at position size and timeframe; prioritize structural liquidity (average daily volume > 1 million shares) Exit: For exit of large positions (>10,000 shares), consider spreading exit across multiple days to avoid moving the market against yourself Key rule: Average daily volume below 500,000 shares = avoid position sizing above 1% of ADV to prevent self-inflicted spread widening
Real example: On 2024-02-07, META reported earnings after close. At 3:30 PM EST (90 minutes before close), META's bid-ask spread was 2 cents — normal. By 3:58 PM (2 minutes before close), the spread widened to 18 cents as market makers pulled quotes ahead of the release. Traders who entered at 3:55 PM paid 9 cents of extra spread on both sides of the trade — 18 cents round-trip — on what was listed as a "zero-commission" platform.
Section 5: Pseudo Code
INPUT: bid[], ask[], trade_prices[] # arrays of real-time quotes and prints
PROCESS:
Step 1: Compute absolute spread per quote update
abs_spread = ask - bid
Step 2: Compute midpoint
midpoint = (ask + bid) / 2
Step 3: Compute relative spread in basis points
rel_spread_bps = (abs_spread / midpoint) * 10000
Step 4: For each trade, compute effective spread
eff_spread = 2 * abs(trade_price - midpoint)
Step 5: Rolling average spread (for liquidity monitoring)
rolling_avg = sum(abs_spread[-N:]) / N # N = number of quotes in window
Step 6: Adverse selection flag
if abs_spread > 2.0 * rolling_avg:
flag = "SPREAD_WIDENING_WARNING"
OUTPUT:
abs_spread[] — absolute spread per quote
rel_spread_bps[] — relative spread in basis points
eff_spread[] — effective spread per trade
flag[] — adverse selection warning flags
EDGE CASES:
- Locked market (bid == ask): valid, spread = 0, common in futures
- Crossed market (bid > ask): data error or latency artifact — skip observation
- Missing ask or bid quote: skip calculation for that timestamp
- After-hours: expect spreads 5-10x wider — flag all trades as high-cost
Section 6: Parameters & Optimization
Standard Measurement Conventions
| Metric | Unit | Use Case |
|---|---|---|
| Absolute spread | Dollars and cents | Daily monitoring for a specific stock |
| Relative spread | Basis points (bps) | Comparing liquidity across different-priced stocks |
| Effective spread | Dollars and cents | Backtesting actual execution costs |
| Time-weighted spread | Bps over session | Fair comparison of liquidity across different sessions |
Parameter Impact
| Change | Effect | When to Apply |
|---|---|---|
| Shorter averaging window | More responsive to sudden widening | Event trading, earnings plays |
| Longer averaging window | Better baseline for anomaly detection | General liquidity monitoring |
| Effective vs. quoted spread | Effective is always larger — captures true cost | Backtesting strategies with market orders |
Why does spread widen before news events?
Market makers are counterparties to every trade. Before a major announcement, they face severe adverse selection risk — informed traders know the news and will trade aggressively against them. To protect against potential losses, market makers widen spreads to require larger favorable moves before they profit. This is rational behavior, not manipulation. The widening is a signal that sophisticated participants expect a significant price move.
Is a zero-commission broker truly free?
Not in the context of spread costs. Payment for order flow (PFOF) — the mechanism used by most zero-commission US retail brokers — routes your orders to market makers who execute at prices slightly worse than the best available quote. The difference is small per trade but adds up significantly for active traders. Interactive Brokers' Pro account (with commissions) typically produces better net execution on high-frequency strategies than zero-commission PFOF brokers.
How do I measure my actual execution quality?
Compare each fill price to the NBBO midpoint at the time of execution. This is called "price improvement vs. midpoint." Most brokers are required to report this metric. A good broker fills you at or better than midpoint on limit orders. A poor broker fills you at or outside the quoted ask/bid on market orders.
Section 7: Synergies & Conflicts
| Works Well With | Avoid Combining With | |
|---|---|---|
| Order Flow Imbalance | Widening spread + rising OFI = informed buying — follow the direction | — |
| Volume Profile | Thin-volume price levels have wider effective spreads — identify levels with execution risk | — |
| VWAP | Spread narrows near VWAP during active sessions — good execution zone for large orders | — |
| ATR | High ATR relative to spread = good reward-to-spread ratio — favorable for active trading | — |
| Fixed R:R targets without spread adjustment | — | A 2:1 R:R target on a wide-spread stock may actually be 1.2:1 after spread costs — always subtract spread from both entry and exit targets |
| Backtests assuming zero spread | — | All backtesting must include realistic spread assumptions — backtests ignoring spread are mathematically wrong |
Section 8: Common Mistakes
| Mistake | Root Cause | Solution |
|---|---|---|
| Using market orders on illiquid stocks | Assumption that fill price will be close to quote | Use limit orders on any stock with spread above $0.05; accept partial fills |
| Ignoring spread in backtest | Backtesting tools default to "trade at close" with no friction | Add spread/2 to buy entries and subtract spread/2 from sell entries in every backtest |
| Trading into earnings without checking spread | Spread can widen 10x — destroys scalp and swing setups | Check spread 2 hours before any scheduled event; delay entry if spread is elevated |
| Treating all "penny stocks" as liquid because they are cheap | Low price + wide spread = very high relative cost | A $2 stock with a 10-cent spread has a 5% round-trip cost — not a "cheap" trade |
| Assuming spread is constant | Spread changes every second | Re-check spread at execution time, not when you decided to trade 10 minutes earlier |
Section 9: Cheat Sheet
USE WHEN: Assessing liquidity before entry, sizing positions in unfamiliar stocks, checking pre-event risk, optimizing order type selection
AVOID WHEN: You are already in a trade (spread does not help with exit timing); using it as a directional signal without OFI confirmation
ENTRY SIGNAL: Spread at or below 5-day average = normal liquidity conditions — proceed with plan; use limit order at midpoint
EXIT SIGNAL: Spread widening more than 2x average during an open position = liquidity deteriorating — tighten stop or reduce size
PARAMETERS: Relative spread in bps for cross-stock comparison; 20-quote rolling average for anomaly detection
CONFLUENCE: Order Flow Imbalance (directional context) + Volume Profile (execution level) + ATR (reward vs. spread ratio)
RISK: Wide spreads silently erode profitability — most retail traders never measure this cost
BEST TIMEFRAME: Real-time assessment before every entry; daily average for stock selection and portfolio liquidity scoring