Market on close: what an MOC order is, and what it promises
An MOC order trades in the closing auction at whatever the closing price turns out to be. What it promises, what it does not, and why it is the default order for systems that decide at the close.
By Baris Demirci · · Rev00
The idea
A market on close (MOC) order is an instruction to buy or sell at the official closing price, whatever that price turns out to be.
It does nothing during the day. It waits for the exchange’s closing auction, where the orders meant for the close are collected and matched at one price. That single price becomes the official close: the last bar on the chart, and the close most backtests are built on.
An MOC order carries one condition, which is timing. It trades only in the closing auction. Unlike a limit on close order, it has no price condition.
What it promises, and what it does not
It promises to get you in or out. An MOC order accepts any closing price, so it goes to the front of the queue in the auction. Orders that will trade at any price are matched before orders with limits. On a liquid, widely traded share or fund, in normal conditions, an MOC order fills in full.
It does not promise a price. You find out what you paid only after the auction is over. Most days the closing price is close to where the share was trading a few minutes earlier. Some days it is not, for example when a large order arrives late or news lands in the final minutes.
Every order type trades one of these off against the other. A market order gives certainty of a fill. A limit order gives certainty of price. An MOC order is the market-order version of the closing auction.
Rules of the auction you need to know
- There is a cutoff. Exchanges stop accepting MOC orders some minutes before the close. In the US that is around ten minutes before. After the cutoff, they generally cannot be changed or cancelled. Many brokers set an earlier cutoff of their own.
- Once it is in, you are committed. If the market moves sharply after the cutoff, the order still trades. An MOC order sent by mistake usually cannot be pulled back in time.
- Imbalances are published. In the final minutes, exchanges publish how many more shares are waiting to be bought than sold at the close, or the reverse. Large imbalances can move the closing price.
- Check that it really goes to the auction. Some brokers offer an “at the close” order that is really an ordinary market order sent just before the bell. That is not the same thing. It pays the spread and may fill at a price that is not the official close.
- The opening has its twin. Market on open (MOO) does the same job in the opening auction.
Why systems use it
Many mechanical rules are written in terms of the close. “If the close is above this level, hold it. If not, sell.” Most backtests fill that decision at the closing price.
An MOC order is the simplest way to make live trading match that assumption. The rule decides on the close, the order trades at the close, and the gap between the backtest and the account stays small. That matters most for systems that trade often and look for small moves, such as those that buy the close and sell the open. Paying the spread on every trade there could cancel out the whole idea.
The closing auction is also where a large share of each day’s trading happens, because index funds and many institutions trade there to match the official close. For an ordinary account in a liquid market, that usually means a deep auction and a fair price.
Where it needs care
- You decide before the close exists. The cutoff means your rule has to be run on prices from a few minutes earlier. Usually the answer is the same. Occasionally a late move changes it, and the backtest, which used the final close, will not show that.
- Thinly traded shares. In a small company’s shares, the closing auction can be shallow, and one MOC order can move the price against you. A limit on close order puts a ceiling or floor on that.
- Unusual days. Index rebalancing days and days when options and futures expire can bring very large closing auctions and unusual imbalances.
- Not every broker or market offers it. Most large exchanges run a closing auction, but the names, times and rules differ, and some brokers only offer MOC on some instruments.
The short version
An MOC order trades in the closing auction at whatever the closing price is. It promises the fill, not the price. For a system that decides at the close, it is the order that makes live trading look most like the backtest. In exchange, you commit before the final price exists, and you accept whatever the auction produces.
Written for people building their own systematic portfolio management process. Nothing here is a recommendation to buy or sell anything. See the disclaimer.