Home › Guides › Stop Out

WHY BOTS FAILFREENO ACCOUNTAUTOMATED TRADE BOTSStop OutThe arithmetic of how bots failEDUCATION ONLY | NO SIGNALSEXAMPLE NUMBERS ARE LABELLEDAUTOMATED TRADE BOTSautomatedtradebots.com
A free page on stop out. Education only, with example numbers labelled.
WHY BOTS FAIL

Stop Out

Short answer

A stop out is an automatic closing of positions by the broker when the margin level falls to the stop out level. It is the step after the warning level, the margin call.

A stop out is the broker closing your positions automatically because the margin level has fallen to a set point. It happens with no regard for your plan, and a bot that adds to losers gets there faster.

The page explains the idea in plain words, works through the arithmetic with a table, and shows how it hits grid, martingale and DCA bots, then tells you what to check before you run one.

  • A worked example with real arithmetic
  • How it hits grid, martingale and DCA bots
  • How to check for it before you run a bot
  • No advice, no signals, no profit promises

Last reviewed 28 October 2026. Education only, not advice.

Free, no account Runs in your browser Worked numbers shown Not advice Examples labelled

Ready to go further

Next: find the move that reaches your stop out

The margin calculator turns leverage, position size and balance into used margin and free margin, so you can see how far price can run.

Reading time6 minutes
Worked exampleExact arithmetic
Tools linked1 on this page
Reviewed28 Oct 2026

What is included

  • What it is, in plain words
  • The formula or mechanism, with exact arithmetic
  • How it hits grid, martingale and DCA bots
  • A check you can run before you switch a bot on

Who it is for

  • People who run or plan to run a trading bot
  • Anyone reading a backtest or a bot sales page
  • Readers who want the numbers, not the pitch
  • Not advice, and not a signal service
Margin level as a grid adds positions on the way down (made-up $1,000 account)0%100%200%300%40 pips80 pips120 pips160 pipsMargin call level (example 100%)Stop out level (example 50%)Stop out at 145 pipsPips the price has fallen from the first buyMade-up account and levels. Each 20 pips the grid buys another 0.1 lot.
The picture for this page. Example numbers are made up unless the page says they were calculated.

Key facts

  • A stop out is an automatic closing of positions by the broker when the margin level falls to the stop out level. It is the step after the warning level, the margin call.
  • Margin level = equity / used margin x 100. Stop out levels vary by broker and account type, so read the terms of yours.
  • The order the positions are closed in, and whether one or all are closed, varies by broker. A common approach is the biggest loser first, but check yours.
  • In the made-up example below a grid reaches its stop out 145 pips below the first buy, at equity $400 on $800 of used margin.
  • A gap, such as over a weekend, can jump past the level, so positions are closed at a worse price than the level suggests.

What a stop out is

Positions on margin need a cushion. Margin level compares the equity in your account with the margin your open positions are holding:

Margin level = equity / used margin x 100

When equity falls, the level falls. Brokers set two lines. The upper one, the margin call level, is a warning or a restriction on opening new positions. The lower one, the stop out level, is where the broker acts. At the stop out level the platform starts closing positions without asking, to free margin and protect itself and you from a larger loss. The levels differ between brokers and account types, so any number on this page is an example only.

Margin call and stop out are different

  • Margin call: a warning or a restriction. Some brokers send a message, some block new orders, and some do nothing visible. Your positions are still open and your decisions are still yours.
  • Stop out: an action. The broker closes positions. Your plan, your take profit, and a bot's recovery logic are all overridden.

Some brokers have only one level. Some skip the warning entirely.

How the closing happens

The details vary by broker, so check yours. In general terms, the platform picks a position, closes it at the market price available, recalculates the margin level, and repeats until the level is back above the stop out level. A common rule is to start with the position with the largest floating loss, but some use the most recent, the largest, or another order. Closing happens at market, so it is exposed to slippage. A partial stop out closes some positions and leaves others open.

A worked example: a grid reaches the stop out

Take a made-up $1,000 account at 100:1 leverage. A grid bot buys 0.1 lot (10,000 units, about $1 per pip, $100 of margin) at the start and again every 20 pips lower. Take the margin call level as 100 percent and the stop out level as 50 percent. These are examples. All figures are calculated by us on 27 Oct 2026, exact for these inputs.

Pips fallenPositions openFloating lossEquityUsed marginMargin levelEvent
01$0$1,000$1001000%
403-$60$940$300313%
805-$200$800$500160%
1006-$300$700$600117%
1176-$402$598$600100%Margin call level reached
1207-$420$580$70083%
1458-$600$400$80050%Stop out level reached

Equity falls slowly at first, because only a few positions are losing. Then each added position makes every further pip cost more, and the loss grows faster than the pip count. Margin used also rises in steps. The margin level crosses 100 percent at 117 pips and 50 percent at 145 pips. The account has not lost everything. At the stop out it has $400 of equity left, about 40 percent of the start, and the grid that was designed to wait for a bounce is cut off.

Partial stop outs

If the broker closes one position at a time, here is what happens next. At 145 pips the position with the largest loss is the first one, losing $145 (145 pips at $1 per pip). Closing it removes $100 of margin but does not change equity, because the loss was already counted. Used margin falls to $700 and the margin level becomes 400 / 700 = 57.1 percent, which is above 50 percent, so the stop out stops. The grid now holds 7 positions and has locked in a $145 loss. If price keeps falling, the level will fall again and the process repeats. A partial stop out is not a rescue, it is the first slice.

Equity and used margin at the stop out (made-up $1,000 account)$1,000Start balance$400Equity at stop out$800Used margin at stop outEquity divided by used margin is 50 percent, the example stop out level.
The stop out comes when equity is only half of the margin the open positions are holding.

Weekend gaps and fast markets

The stop out level is a trigger, not a price. If the market jumps, the broker closes at the first prices available, which can be far beyond the level. Suppose the grid above has 7 positions open with price 120 pips down, and the market reopens after a weekend 200 pips down, with no new grid levels filled. Equity was $580. The 7 positions lose another 7 x 80 = $560, which leaves $20. The account is closed out at almost nothing. Past a gap of about 83 pips from 120 the equity goes below zero, which is the subject of negative balance.

What a stop out does to a bot

  • Grid bots: the whole basket is cut, often close to the low, so the bounce they were waiting for comes after they are closed.
  • Martingale bots: the most recent steps are the largest, and a bot built to double again is stopped out at exactly the point it would have doubled. See martingale.
  • DCA bots on leverage reach it more slowly, but the same arithmetic applies to margin.
  • Any bot may reopen right after, using what is left, which starts the same ladder on a smaller account.

How to check before you run a bot

  • Find the stop out level in your account terms, and whether it is a percentage or a currency amount. Check for a margin call level too.
  • Find out how your broker chooses which position to close, and whether it closes one or all.
  • Work out the largest stack the bot can build, the margin it needs, and the price move at which the margin level reaches the stop out. The margin calculator does the first part.
  • Add weekends, news and holidays. Check how your broker treats positions held over a gap.
  • Run the bot on a demo account through a fast move before real money, and check whether the demo uses the same stop out level as the live account.

What it does not tell you

The stop out level says when the broker acts, not whether the strategy was sound. A margin level above the stop out does not mean the account is safe, because a gap can skip the level. The example here is an invented account with a plain grid. Real instruments have different contract sizes, and margin can change with leverage rules, so compute with your own terms.

FAQ

Frequently Asked Questions

What is the difference between a margin call and a stop out?

A margin call is the warning level, and a stop out is the level where the broker starts closing positions. Some brokers send no warning. Check the levels in your account terms.

Which position does the broker close first?

It varies by broker. A common method is the position with the largest floating loss first, but others close the newest, the oldest or the largest position. Read how yours does it.

Does a stop out close all my positions?

Not always. Many platforms close one at a time and recheck the margin level after each. The process stops once the level is back above the stop out level, which leaves a partial position behind.

Can I avoid a stop out with a stop loss?

A stop loss can close a position before the margin level reaches the stop out, but only if it triggers and fills first. A gap can skip it. Use it with a limit on the total margin the bot may use.

Can a stop out leave me owing money?

On some account types it can, if the price gaps past the stop out and the loss exceeds the balance. Whether the broker covers the shortfall varies, so read the terms. See the negative balance page.

Are the numbers on this page real?

Example numbers are made up to show how the maths works, and the page says so. A figure only counts as exact when the page says it was calculated on a stated date. Nothing you enter in a calculator leaves your browser.

Can I use this to decide whether to run a bot?

It can show whether a bot's numbers hold together and how much an account can lose. It cannot say what the market will do, and it is not advice. Use it to ask better questions, then read the terms of your own broker or exchange.

Is this financial advice?

No. It explains how a broker mechanism works in general terms. The account, levels and prices are made up, with exact arithmetic.

Know the Risk Before You Run It

Free calculators and guides, added every week. Leave your details and we will email you when new ones go up.

Trading carries a risk of loss