Execution & trading costs

Market order

Market order is an instruction to buy or sell a security at the best available price when the order reaches the market, without setting a maximum buy price or minimum sell price.

What it means

A market order prioritizes getting an order filled over controlling its price. A market buy generally takes available offers, starting at the lowest ask; a market sell generally takes available bids, starting at the highest bid. The price shown when you submit an order may differ from its eventual fill price. A fill is not guaranteed, particularly if trading is halted or available liquidity is insufficient.

A limit order sets a maximum price for a buy or a minimum price for a sell. It may fill at that price or better, but it can remain unfilled. A market order has no such price boundary. Neither order type guarantees a particular outcome.

How it is calculated

A market order is an instruction, not a calculated number. Its estimated spread cost can be expressed relative to the quoted midpoint:

Estimated spread cost = quantity × (expected fill price − midpoint) for a buy; Estimated spread cost = quantity × (midpoint − expected fill price) for a sell.

  • Quantity is the number of shares.
  • Expected fill price is the estimated price per share, in US$; an actual fill may differ.
  • Midpoint is (best bid + best ask) ÷ 2, in US$ per share, using quotes observed at the time of the estimate.
  • Estimated spread cost is in US$ and excludes commissions, fees, market impact beyond the assumed fill price, and subsequent price moves.

If the full order fills at the quoted best ask for a buy or best bid for a sell, its estimated spread cost is half the quoted spread times the share quantity. If the order consumes multiple price levels, that shortcut understates its cost relative to the original midpoint.

Worked example

Suppose, hypothetically, a stock has a best bid of US$49.00 and a best ask of US$51.00. You submit a market order to buy 100 shares.

  1. The quoted spread is US$51.00 − US$49.00 = US$2.00 per share; the midpoint is (US$49.00 + US$51.00) ÷ 2 = US$50.00.
  2. If 100 shares are available at the ask and the entire order fills at US$51.00, the purchase costs 100 × US$51.00 = US$5,100, excluding fees.
  3. Relative to the quoted midpoint, spread cost is 100 × (US$51.00 − US$50.00) = US$100, or US$1.00 per share. The opposite-side bid is US$49.00; an immediate sale of all 100 shares at that unchanged bid would bring US$4,900, a US$200 round-trip difference before fees.

Those figures assume the quotes and available shares do not change. If only 40 shares are offered at US$51.00 and the next 60 fill at US$52.00, the average fill is US$51.60 and the buy-side cost relative to the original midpoint rises to US$160. These are hypothetical prices, not a prediction of any fill.

Why it matters before you trade

A wide spread makes the cost of immediately taking the available bid or ask larger relative to the midpoint. It can be especially important when a stock has limited liquidity or an order is large relative to the shares available at the best quote. The displayed bid and ask alone do not tell you how many shares can fill at those prices; quotes can also change while an order is being routed.

A pre-trade check can compare the order size with typical volume, examine estimated spread and market impact, and consider whether price certainty or the possibility of an unfilled order matters more. A limit order defines a price boundary, but that boundary does not guarantee execution.

How PreTrAIde uses it

PreTrAIde provides pre-trade analysis for stock baskets before orders are placed. Its quantitative layer estimates bid-ask spread, participation in daily volume and market impact, and produces liquidity and execution scores. Its basket and per-stock verdicts include a suggested execution strategy and plain-language reasoning. These estimates can inform a review of potential execution costs; they do not establish the price a market order will receive. PreTrAIde does not receive, transmit or execute orders. Users trade through their own broker.

Common mistakes

  • Treating the last traded price as a fill quote. A market buy can fill at the ask or higher; a market sell can fill at the bid or lower.
  • Counting only half the spread as total cost. Fees, changes in quotes and fills across multiple price levels can add to the cost.
  • Assuming a limit order is certain to fill. It controls the acceptable price, not whether another participant trades at that price.
  • Assuming a market order guarantees an immediate, complete fill. A halt, limited liquidity or changing market conditions can prevent or delay execution.

Frequently asked questions

What is the difference between a market order and a limit order?

A market order has no maximum buy price or minimum sell price. A limit order sets that price boundary, but may not fill.

Why does a market order cost more when the bid-ask spread is wide?

A market buy typically takes the ask and a market sell typically takes the bid. The wider those quotes are apart, the greater the cost relative to their midpoint, assuming a fill at the quoted price.

Can a market order fill at a different price from the quote I saw?

Yes. Quotes can change before the order reaches the market, and an order larger than the available shares at the best price can fill across multiple price levels.

Related terms

Execution & trading costs

Pre-trade analysis Post-trade analysis Transaction cost analysis (TCA) Effective spread Realized spread Midpoint price Implementation shortfall Transaction costs All glossary terms →

Check your next trade before you place it

Build a basket, run a pre-trade analysis, and get a GO, NO-GO or MODIFY verdict with the cost, liquidity and risk behind it.

Start your free trial Try the free tools

Educational content, not investment advice. PreTrAIde is analysis software, not a broker: it never executes orders, and its verdicts are decision support, not recommendations to buy or sell.