Home / Blog / How to limit risk in a gold grid EA: the settings that matter

How to limit risk in a gold grid EA: the settings that matter

In short: To limit a gold grid EA's risk, put more balance behind each lot and use fewer orders. Filters and stops help less, and no setting rules out a stop-out.

Grid risk controls: $ per lot More balance behind each lot and fewer orders help most; no setting rules out stop-out
$ per lot More balance behind each lot and fewer orders help most; no setting rules out stop-out

The settings that limit a grid EA's risk are, roughly in order of strength: balance behind each lot, the number of orders, the hours it may start in, a spread limit, and emergency stops. Each one gives something up. Entry filters only choose when a basket starts. None of them removes the chance of a stop-out; the arithmetic below shows how much room each one buys.

Written on 9 October 2026. The names of settings come from Midas, an MT5 gold grid EA, but the logic fits any doubling grid. This is arithmetic of settings, not a forecast.

See also: 7 protections for a martingale grid bot on gold →

On this page (11)

What limits the risk of a gold grid EA?

In a gold grid EA, risk is limited mainly by how much balance stands behind each lot and by how many orders the grid may open. Hours, a spread limit, stops, a lock and alerts help less, and none of them removes the chance of a stop-out.

A doubling grid has one exposure: lots multiplied by distance. Every order added makes the position bigger, and the loss grows faster than the price moves. So the controls fall into four groups:

  • Size: how much balance stands behind each lot, and how many orders the grid may open.
  • Time: when a new basket may start, and when orders should pause.
  • Exit: a point at which a loss is taken on purpose.
  • Attention: a signal that tells you the basket is getting deep.

An entry indicator sits outside these four: it changes when a basket starts, not how big it can get.

How much does the number of orders change the room?

The number of orders changes the room to stop-out more than any other single number: in the example below, each order removed roughly halves the total lots and about doubles the room.

Take a cent account of $1,000, base lot 0.01, lot doubling, step $1.95, leverage 1:2000, stop-out at 40%, gold at $4,170 (the grid calculator defaults). Room is how far price can still fall after the last order before the stop-out.

OrdersTotal lotsGrid depth, $Floating loss at last order, $Room after last order, $
1120.4719.5039.7046.08
1010.2317.5519.7594.99
95.1115.609.79192.95
82.5513.654.82389.43

Calculated on 9 October 2026; spread and slippage are not included.

One order less roughly halves the lots and about doubles the room.

The cost is real. With a lower ceiling the grid stops adding earlier, so a basket standing at order 9 cannot add the larger orders that would have pulled its average price closer. It recovers less ground when price returns. For how step, multiplier and count interact, see grid step, multiplier and order count.

How much balance does a gold grid EA need?

No single deposit fits: the balance a gold grid needs depends on the lot, the number of orders, the step and the leverage, and the grid calculator shows it for your own settings. In the calculator example (11 orders, base lot 0.01, step $1.95, gold at $4,170), $500 leaves $21.65 of room, $1,000 leaves $46.08 and $2,000 leaves $94.93.

Twice the lot needs twice the balance for the same room. This is arithmetic, not a recommended deposit.

When should a grid EA be allowed to start a basket?

A new basket in a gold grid EA can be gated three ways: by a trading-hours window, by news windows you type in, and by a spread limit. None of them touches a basket that is already open.

Trading hours. A window in broker server time, for example new baskets only from 07:00 to 19:59. It keeps new baskets out of hours you consider thin or unattended. Check which clock your broker's server runs on; XAUUSD hours, sessions, spread and swap explains the offsets. By default an open basket still adds orders through the night.

News windows. Midas reads no calendar, so you type the time ranges yourself, converted to server time (gold on news days). A window stops new baskets, and optionally refills, around a release. Unscheduled news has no window.

Spread limit. The EA pauses orders while Ask minus Bid is above a number you set. In a wide-spread moment the basket also cannot add its next order. Set it under your broker's normal spread and the EA idles all day.

All three reduce how many baskets start. None of them can shorten a move against a basket that has started.

What does a hard stop or an equity stop do?

A hard stop or equity stop in a grid EA closes the basket at a loss you chose, so a bad basket cannot grow to the stop-out. The price is that the loss becomes final even if price would have come back.

Use the same example. When all 11 orders are open the floating loss is $39.70, and each further $1 against the grid adds $20.47, because the calculator counts $1 per $1 of gold per lot on a cent account, and 20.47 lots are open. A hard stop of 30% of balance is $300. It fires about $12.7 below the last order, since (300 - 39.70) / 20.47 = 12.7. The stop-out in the same example sits $46.08 below the last order.

So the stop trades a possible stop-out for a certain loss of $300 earlier. If price would have come back, you gave up the recovery. If it would not, you kept the rest of the balance. Nobody knows which in advance; the setting is a decision about what loss you can accept for certain.

Limits you should know:

  • It closes at market. A gap or slippage can take the result beyond $300.
  • The percentage check runs while the terminal is running. If MT5 or the VPS is down, nothing checks.
  • A stop attached to each order on the broker's server works with the terminal off. But with a doubling grid each order has its own stop, so they close one by one, oldest first, and the distance must be larger than the whole grid depth. Try it on demo first.

In Midas these are HardStopPct, EquityKillPct, CooldownMin and EmergencySLUsd, all off by default. See Protection and filters.

Does locking a grid basket limit the loss?

Only partly. A lock opens an opposite-direction order for a share of the basket on a hedging account, and the floating loss on the locked share stops growing while the lock stands. Nothing is closed, spread is paid and a stop-out stays possible.

The unlocked share still moves, and removing the lock later may realise the loss. See locking a position in forex for the mechanics.

With an automatic lock and a hard stop together, set the lock's threshold lower than the stop's, or the stop closes the basket first.

Do phone alerts count as protection?

A phone alert from a grid EA counts as protection only if you act on it. A push to your phone when the basket reaches order 6 of 11 gives you five orders of notice. It trades nothing, and it needs a MetaQuotes ID entered in the desktop terminal plus the MT5 mobile app (the MQL5 documentation describes the notification function). A signal you never read protects nothing.

Do entry filters or Smart Money tools limit risk?

No. Entry filters, Smart Money included, do not limit how large a basket grows or how far price can go against it. They are checked when a new basket is about to start and not afterwards, so they cannot shorten a move against a basket already open. Midas has them, switched off by default, and does not claim they improve results. The full explanation is in entry filters and Smart Money.

Where are these controls in Midas?

ControlWhereDefault
Start lot, orders in grid, stepPanel, Grid tab0.01, 11, $1.95
Trading hoursPanel Grid tab; F7 "Trading hours & refills"06 to 22 server
News windowsF7 "Protection": NewsWin1, NewsWin2, BlockExpandInNewsempty, off
Spread limitF7 "Protection": MaxSpread2.50
Hard and equity stopsF7 "Protection": HardStopPct, EquityKillPctoff
Auto-lockPanel, Auto-lock taboff
Phone signalPanel Alerts tab; F7 NotifyKneesorder 6

Midas has no weekday filter and no automatic news calendar, and its grid step does not grow with depth.

What can go wrong

  • Every control is a trade-off. A tighter ceiling, window or stop lowers one exposure and creates another, such as lost recovery or idle hours.
  • Numbers from a calculator are not live results. Spread, slippage and gaps move them. Whether a balance can end below zero after a gap depends on your broker's terms; see can a forex account go negative.
  • If the deposit is too small, a stop-out is possible. A cent account makes the numbers small, not the risk. Read Risk, plainly.

For your own balance, use the grid calculator and the margin calculator.

This is arithmetic of the settings, not a forecast. Trading with leverage carries risk: if the deposit is too small, a stop-out is possible. Size your deposit with a safety margin. Nothing here is individual investment advice.

Midas · published 9 October 2026 · updated 9 October 2026 · figures calculated on 9 October 2026.

See also: how a gold grid EA works.

FAQ

Can any setting remove the risk of a grid EA?

No. Settings change how much room you have, when baskets start and where a loss is taken. They do not remove the stop-out, and none of them knows where price will go. The most they do is make the exposure something you chose in advance. Each one also has a cost, such as lost recovery or idle hours.

How many orders should a grid have?

There is no right number, because it depends on balance, lot, step and leverage. At the same balance, fewer orders mean fewer lots and more room to the stop-out, at the price of less averaging: in the article's example ($1,000 balance, base lot 0.01, step $1.95), one order less about doubles the room. Put your own numbers into the grid calculator instead of using a rule of thumb.

What is the difference between a hard stop and a stop-out?

A hard stop is your own setting: the EA closes the basket at market at a loss you chose, while the terminal is running, so a gap or slippage can take the result beyond it. A stop-out is the broker closing positions by force when margin level falls below its threshold, at whatever price is available. See margin call vs stop-out.

What is a grid EA, and how does grid trading work on gold?

A grid EA opens a first order and adds more at set price steps as price moves against it, up to a set maximum, and manages all of them as one basket. A doubling grid has one exposure, lots multiplied by distance, so each added order makes the position bigger. On a cent account one lot moves the balance by $1 per $1 of gold.

What should I check in a grid EA before using it?

Check the balance behind each lot, how many orders the grid may open, whether any stop exists and how much room is left to the stop-out after the last order. The grid calculator shows that room for your own numbers. Test on a demo account, and use the ten questions in how to evaluate a gold EA for the seller's claims.