EA Position Sizing Calculator (Step-by-Step)
Position sizing formula for EA trading: Lot Size = (Account Balance x Risk %) / (Stop Loss in pips x Pip Value). For a $1,000 XAUUSD account with 2% risk and 300-pip stop: 0.07 lots. For a $5,000 account: 0.33 lots. Getting position sizing right is the single most important factor in long-term EA survival.
Position sizing determines how much you risk on each trade, and it is the difference between an EA that grows your account steadily and one that blows it up during a losing streak. I have seen traders with excellent EAs destroy their accounts because they used lot sizes that were far too large. In this tutorial, I will walk you through the exact position sizing formulas, provide ready-to-use calculations for every account size, and explain how to configure your EA for optimal risk management.
In This Tutorial
The Position Sizing Formula
Every position sizing calculation starts with this core formula:
Lot Size = (Account Balance x Risk Percentage) / (Stop Loss in Pips x Pip Value per Lot)
Let me break down each component:
- Account Balance: Your current account equity (use equity, not balance, if you have open trades)
- Risk Percentage: The maximum percentage you are willing to lose on a single trade (typically 1-3%)
- Stop Loss in Pips: The distance from entry to stop loss in pips
- Pip Value per Lot: How much one pip is worth per standard lot (varies by instrument)
XAUUSD Pip Value Reference
For gold (XAUUSD), most brokers define one pip as $0.01 price movement. The pip value per lot type:
| Lot Size | Ounces | Pip Value ($0.01 move) | Value of $1 Move |
|---|---|---|---|
| 0.01 (Micro) | 1 oz | $0.01 | $1.00 |
| 0.10 (Mini) | 10 oz | $0.10 | $10.00 |
| 1.00 (Standard) | 100 oz | $1.00 | $100.00 |
Gold Position Sizing: Worked Examples
Example 1: $1,000 Account, 2% Risk, 300-Pip Stop Loss
- Risk amount: $1,000 x 2% = $20
- Stop loss value needed: 300 pips x pip value per lot = cost
- At 0.01 lot: 300 x $0.01 = $3.00 risk
- Lot size: $20 / $3.00 = 0.067 lots (round to 0.07)
- If stop loss is hit, you lose approximately $21 (2.1% of account)
Example 2: $5,000 Account, 2% Risk, 300-Pip Stop Loss
- Risk amount: $5,000 x 2% = $100
- Lot size: $100 / $3.00 = 0.33 lots
- If stop loss is hit, you lose $99 (1.98% of account)
Example 3: $10,000 Account, 1% Risk, 500-Pip Stop Loss
- Risk amount: $10,000 x 1% = $100
- Stop loss cost at 0.01 lot: 500 x $0.01 = $5.00
- Lot size: $100 / $5.00 = 0.20 lots
Ready-to-Use Lot Size Table
Here are pre-calculated lot sizes for XAUUSD with a typical 300-pip stop loss at different account sizes and risk levels:
| Account Size | 1% Risk | 2% Risk | 3% Risk |
|---|---|---|---|
| $500 | 0.02 | 0.03 | 0.05 |
| $1,000 | 0.03 | 0.07 | 0.10 |
| $2,000 | 0.07 | 0.13 | 0.20 |
| $5,000 | 0.17 | 0.33 | 0.50 |
| $10,000 | 0.33 | 0.67 | 1.00 |
| $25,000 | 0.83 | 1.67 | 2.50 |
| $50,000 | 1.67 | 3.33 | 5.00 |
These calculations assume a 300-pip stop loss. If your EA uses a different stop loss distance, adjust proportionally. A wider stop loss requires smaller lot sizes; a tighter stop loss allows larger lots for the same risk percentage.
Choosing Your Risk Level
| Risk Level | % Per Trade | Best For | 10-Loss Streak Impact |
|---|---|---|---|
| Ultra Conservative | 0.5% | Large accounts, capital preservation | -4.9% drawdown |
| Conservative | 1% | Most traders, steady growth | -9.6% drawdown |
| Moderate | 2% | Balanced growth and safety | -18.3% drawdown |
| Aggressive | 3% | Small accounts seeking growth | -26.3% drawdown |
| Very Aggressive | 5% | Not recommended | -40.1% drawdown |
I recommend 2% risk for most EA traders. It provides meaningful growth while surviving inevitable losing streaks. Even a well-performing EA with an 81% win rate will occasionally have 5-7 consecutive losses. At 2% risk, a 7-loss streak costs approximately 13% of your account -- recoverable within a few winning trades. At 5% risk, the same streak costs 30% -- much harder to recover from.
For a deeper understanding of risk management principles, read our complete risk management guide.
Auto Lot Sizing vs Fixed Lot Sizing
Auto Lot Sizing (Risk-Based)
- Calculates lot size based on current balance and risk percentage
- Automatically scales up as account grows (compounding)
- Automatically scales down during drawdowns (protection)
- Recommended for most traders
Fixed Lot Sizing
- Uses the same lot size regardless of account balance
- Simpler to understand and monitor
- Does not compound -- growth is linear, not exponential
- Risk percentage changes as balance fluctuates
For long-term account growth, auto lot sizing with compounding produces significantly better results. Our account growth guide shows the dramatic difference compounding makes over 6-12 months.
Maximum Exposure Rules
Position sizing per trade is important, but total portfolio exposure matters even more. Follow these rules to prevent catastrophic drawdowns:
- Maximum 3-5 simultaneous trades at 2% risk each = 6-10% total exposure
- Never exceed 10% total account risk across all open positions
- Reduce lot sizes by 50% after a 15% drawdown until recovery
- Stop trading entirely at 25% drawdown and review EA performance
- Correlate position risk: If all trades are on XAUUSD, they are effectively one large position
Warning: The number one account killer is excessive position sizing. Trading too large feels exciting when winning but devastating during inevitable drawdowns. Discipline with position sizing separates successful traders from blown accounts. For guidance on starting capital, see our how much to start EA trading guide.
Frequently Asked Questions About Position Sizing
How do I calculate the right lot size for my EA?
Use: Lot Size = (Account Balance x Risk %) / (Stop Loss in pips x Pip Value). For a $1,000 account with 2% risk and 300-pip stop on XAUUSD: ($1,000 x 0.02) / (300 x $0.01) = 0.07 lots.
What risk percentage should I use for EA trading?
Use 1-2% per trade for conservative trading, 2-3% for moderate. Never exceed 5%. With an 81% win rate EA, 2% provides strong growth while surviving consecutive losses.
What lot size for a $1,000 gold trading account?
With 2% risk and 300-pip stop loss: 0.07 lots. With 1% risk: 0.03 lots. These sizes keep a single loss at $20 or $10 respectively.
Should I use fixed or auto lot sizing?
Auto lot sizing is better for most traders. It scales with your balance, compounding gains and reducing risk during drawdowns. Fixed lots are simpler but do not adapt to balance changes.
How many simultaneous trades should my EA open?
Limit total exposure to 6-10% across all open trades. At 2% risk per trade, that means 3-5 simultaneous positions maximum to prevent excessive drawdown during volatile markets.