Black FridaySave 79%$2,388 $499/yearBlack Friday price, for a limited time · Price locked at $499
All articles
RiskUpdated 6 min

Risk Management for Expert Advisors (MT4 and MT5): A Practical Guide

Position sizing, risk per trade, drawdown limits and the settings to check before you let an Expert Advisor trade, with worked examples and a checklist.

Gixodia Risk Team
Risk Management · MT4 · EA

A strong strategy with weak risk controls can still empty an account. This guide covers how to think about risk when you run an Expert Advisor (EA) on MetaTrader 5. Gixodia's bots run on MT5, but every principle here applies the same way on MT4.

What risk management means for an EA

An EA decides when to enter and exit. Risk management decides how much each decision can cost. It covers four things:

  • Risk per trade: how much of the account one losing trade can take.
  • Exposure: how much is at risk across all open positions at once.
  • Drawdown limits: the point at which trading stops.
  • Your own behaviour: whether you leave the rules alone once they are set.

Position sizing: the formula

Position size connects your risk limit to the market. The calculation:

  1. Choose a risk per trade as a percentage of the balance.
  2. Convert it to money (balance times percentage).
  3. Measure the stop-loss distance in pips or price units.
  4. Divide the money at risk by (stop distance times value per pip or per unit at 1 lot).

Example (hypothetical numbers): a $2,000 account risking 1% per trade risks $20. On EUR/USD, 1 standard lot is worth about $10 per pip, so with a 25-pip stop: $20 divided by (25 x $10) = 0.08 lots. Round down to the broker's lot step, never up.

The Kelly criterion, and why traders use a fraction of it

The Kelly criterion is a formula that gives the theoretically optimal fraction to risk, given a win rate and a reward-to-risk ratio: win rate minus (loss rate divided by reward-to-risk). Example (hypothetical numbers): with a 60% win rate and a 1.2 reward-to-risk ratio, Kelly gives 0.60 minus (0.40 / 1.2), about 27% of capital per trade.

Nobody sensible trades that. Kelly assumes you know your true edge exactly, but you only ever have an estimate from past data, and a small error leads to large overbetting. Practitioners who use Kelly at all use a fraction of it, often a quarter or less.

Why "1% per trade" is not automatically safe

"Risk 1% per trade" is common advice. It sounds small, but losing streaks compound. The arithmetic (hypothetical, risking a fixed percentage of the current balance):

  • 10 losses in a row at 1%: about 9.6% down, needing about 10.6% to recover
  • 15 losses in a row at 1%: about 14% down, needing about 16.3% to recover
  • 10 losses in a row at 2%: about 18.3% down, needing about 22.4% to recover

Recovery is non-linear: after a 50% loss you need a 100% gain to get back to even. Whether 1% is appropriate depends on the strategy, the account and how you would cope with a long streak. Lower risk means smaller swings in both directions.

Maximum adverse excursion (MAE)

Every trade has a worst moment: the furthest it moved against you before it closed. That is its maximum adverse excursion. If you review MAE across many past trades in your MT5 history, you can see how far winning trades usually move against you before they work. A stop placed well inside that range gets hit by ordinary noise; a stop far outside it risks more than needed. MAE review is a way to question stop placement with data instead of guesswork.

Correlation: two EAs can be one bet

If you run two EAs on the same account, for example one on gold and one on EUR/USD, you are not running two independent bets. Both instruments often react to the US dollar. On days when the dollar moves sharply, both positions can win or lose together. Add up the exposure across everything on the account, not one EA at a time.

Drawdown stops: the circuit breaker

A drawdown stop pauses or stops trading once the account falls a set amount. It is the rule that keeps a bad stretch from becoming a disaster. When you set one:

  1. Decide the maximum loss you accept on the account, in money, before the EA starts.
  2. Set the EA's account or balance stop at or below that level.
  3. On a prop firm account, set it below the firm's own drawdown limit, leaving room for spread and slippage.

Why manual intervention breaks risk rules

People bend their own rules: they widen a stop "just this once", average down on a loser or raise size after a win. An EA applies the same rules on every trade, but only if you leave it alone. Turning it off mid-drawdown, or raising its risk after a good week, puts emotion straight back into the system.

How Gixodia fits

GIX-PROP (EUR/USD) and GIX-PROP GOLD run on prop firm accounts and include a built-in balance stop you can set lower to fit the firm's drawdown limits; check first that the firm allows EAs. GIX-GOLD is an aggressive gold EA for your own broker account from $1,000: losses can be fast and large, and you choose the account stop. You can try them on a demo account during the 72-hour free trial of the annual license at /start.

Gixodia's Historical Drawdowns

For reference, the drawdowns Gixodia publishes for its own software: 5.8% in the 2022 bear market and 6.3% during the 2024 geopolitical shocks. Past results do not guarantee future results, and GIX-GOLD is aggressive by design, so its swings can be larger.

FAQ

Do these principles apply to MT4 as well as MT5?

Yes. Position sizing, drawdown stops and correlation work the same on both platforms. Only menus and some settings differ.

What is a sensible risk per trade?

There is no universal number. It depends on the strategy, account size and how much loss you can tolerate. Run the streak arithmetic above with your own numbers.

Does a drawdown stop cap my loss exactly at its level?

No. Gaps, slippage and fast markets can push losses past a stop level. Nothing is guaranteed.

Trading involves risk and you can lose money. Past results do not guarantee future results. Gixodia is software, not financial advice.

#Risk Management#MT4#EA#Professional
Ready to automate?

Activate your 72-hour free trial with hands-on setup help

Start your 72-hour free trial in minutes, no call required. Card required to start, cancel anytime in your dashboard, no charge if you cancel during the trial.

Risk Management for Expert Advisors (MT4 and MT5): A Practical Guide | Gixodia Blog