What is 'Matching Orders'

Matching orders is the process by which exchanges match buy orders, or bids, with sell orders, or asks, to execute securities trades. Most securities exchanges match orders using computer algorithms. Previously, brokers matched orders through face-to-face interactions on a trading floor in an open-outcry auction.

Breaking Down 'Matching Orders'

Matching orders happen when compatible buy orders and sell orders for the same security happen at the same time. Generally, a buy order and a sell order are compatible if the maximum price of the buy order matches or exceeds the minimum price of the sell order. From there, the order-matching systems of different exchanges use a variety of methods to prioritize orders for matching.

Quick, accurate order matching is critical component of an exchange. Investors, particularly active investors and day traders, will look for ways to minimize inefficiencies in trading from every possible source. A slow order-matching system may cause buyers or sellers to execute trades at less-than-ideal prices, eating into investors’ profits. Some order-matching protocols tend to favor buyers, while others favor sellers. Often, exchanges aim to prioritize trades in a way that benefits buyers and sellers equally.

Popular Algorithms for Matching Orders

Each securities exchange uses its own specific algorithm to match orders. Broadly, they fall under two categories: first-in-first-out (FIFO) and pro-rata.

Under a basic FIFO algorithm, or price-time-priority algorithm, the earliest active buy order at the highest price takes priority over any subsequent order at that price, which in turn takes priority over any active buy order at a lower price. For example, if a buy order for 200 shares of stock at $90 per share precedes an order for 50 shares of the same stock at the same price, the system must match the entire 200-share order to one or more sell orders before beginning to match any portion of the 50-share order.

Under a basic pro-rata algorithm, the system prioritizes active orders at a particular price proportional to the relative size of each order. For example, if both a 200-share buy order and a 50-share buy order at the same price are active when a compatible 200-share sell order arrives, the system will match 160 shares to the 200-share buy order and 40 shares to the 50-share buy order. Since the sell order is not large enough to fulfill both buy orders, the system will partially fill both. In this case, the pro-rata matching algorithm fills 80 percent of each order.

RELATED TERMS
  1. Open Order

    An open order is an order to buy or sell a security that remains ...
  2. Continuous Trading

    Continuous trading is a method for transacting security orders. ...
  3. Held Order

    A held order is a market order that requires prompt execution ...
  4. Conditional Order

    A conditional order is an order that includes one or more specified ...
  5. Box-Top Order

    A box-top order is an order to buy or sell the best market price. ...
  6. Time In Force

    Time in force is an instruction in trading that defines how long ...
Related Articles
  1. Investing

    Understanding Market Orders And Limit Orders

    A market order executes a transaction as quickly as possible at the present price. Immediacy is the main concern. A limit order is executed at or below a purchase or sale price. Price is the ...
  2. Trading

    Basics of algorithmic trading: Concepts and examples

    Algorithmic trading provides a more systematic approach to active trading than one based on a human trader’s intuition or instinct. Here’s how it works.
  3. Investing

    Narrow Your Range With Stop-Limit Orders

    With stop-limit orders, buyers protect themselves from prices too high for their tastes.
  4. Investing

    The Opening Cross: How Nasdaq Stock Prices Are Set

    Learn how the opening cross auction process determines prices of Nasdaq-listed securities at market open to ensure liquidity by matching buyers or sellers.
  5. Investing

    Understanding Buy Stop Orders

    A buy stop order is an order to buy a stock at a specific price above its current market price.
  6. Trading

    What's The Difference Between A Stop And A Limit Order?

    Find out what separates these two market orders and what they can do for you.
RELATED FAQS
  1. The difference between a market order and limit order

    Market orders execute a trade to buy or sell immediately at the best available price. A limit order only trades when the ... Read Answer >>
  2. What exactly is being done when shares are bought and sold?

    Most stocks are traded on physical or virtual exchanges. The New York Stock Exchange (NYSE), for example, is a physical exchange ... Read Answer >>
  3. What is the difference between a buy limit and a stop order?

    Learn the difference between buy limit orders and stop orders, including stop loss orders, and understand the risks of the ... Read Answer >>
  4. How long does it take a broker to confirm a trade after it is placed?

    Learn about placing trades with a broker and the amount of time required to received confirmation of different types of orders. Read Answer >>
Trading Center