MT4 & MT5 Position Sizing

Forex Lot Size & Position Size Calculator

A forex lot size calculator determines your optimal trade volume from account equity, risk tolerance, and stop-loss distance. Using the formula Lots = (Account Balance × Risk %) / (Stop Loss Pips × Pip Value per Standard Lot), traders size MT4 and MT5 positions consistently across currency pairs and XAU/USD without overexposing capital.

Position Sizing TicketEUR/USD · MAJOR
1 PIP = 0.0001 · CONTRACT = 100,000 UNITS
Account Base Currency

Pip: 0.0001 • Lot: 100,000 units

$
%
Direct Quote Match (USD = USD)

No FX conversion required (rate = 1.0000). Pip Value / Lot = Pip Size × Contract Size.

Recommended Position SizeEUR/USD
0.40Standard Lots
Mini Lots (0.10)
4.00
Micro Lots (0.01)
40.0
Trade Units
40,000 units
Capital at Risk
$100.00
Pip Value / 1.00 Lot
$10.00
Pip Value at Size
$4.00
Calculation Formula
$100.00 ÷ (25 pips × $10.00/pip) = 0.40 lots

Forex & Gold Lot Sizes Comparison Table

Contract sizes and typical pip values across MetaTrader order volumes

Lot TierMT4/MT5 VolumeContract SizeApprox. Pip Value (USD)Typical Use Case
Standard Lot1.00100,000 currency units$10.00 / pipLarger accounts ($10,000+) & institutional scaling
Mini Lot0.1010,000 currency units$1.00 / pipMid-sized accounts ($1,000–$10,000) & swing trading
Micro Lot0.011,000 currency units$0.10 / pipSmall live accounts, granular EA scaling & prop challenges
Nano Lot0.001100 currency units$0.01 / pipCent / nano accounts (100 cents = $1) & micro-grid testing
XAU/USD Standard1.00100 troy oz (Gold)$1.00 / 0.01 pipMetals trading ($100 per $1.00 move in spot gold)

Worked Step-by-Step Lot Size Calculation Examples

Example 01 • EUR/USD

USD Account on a Direct Quote Pair

  • Account Balance: $10,000 USD
  • Risk per Trade: 1.0% ($100.00)
  • Stop Loss: 25 pips
  • Pip Value (1.00 lot): 0.0001 × 100,000 = $10.00
Lots = $100 / (25 × $10.00) = 0.40 standard lots (40,000 units)
Example 02 • USD/JPY

USD Account with JPY Conversion

  • Account Balance: $10,000 USD
  • Risk per Trade: 1.0% ($100.00)
  • Stop Loss: 30 pips @ USD/JPY = 150.00
  • Pip Value (1.00 lot): (0.01 × 100,000) ÷ 150 = $6.67
Lots = $100 / (30 × $6.6667) = 0.50 standard lots (50,000 units)
Example 03 • XAU/USD (Gold)

Spot Gold (100 oz Contract)

  • Account Balance: $10,000 USD
  • Risk per Trade: 1.0% ($100.00)
  • Stop Loss: 200 pips ($2.00 price stop)
  • Pip Value (1.00 lot): 0.01 × 100 oz = $1.00 / pip
Lots = $100 / (200 × $1.00) = 0.50 standard lots (50 oz)

Fixed-Risk Position Sizing Inside MetaTrader Expert Advisors

Manual traders calculate lot sizes before clicking Buy or Sell, while MetaTrader Expert Advisors (EAs) automate position sizing programmatically on every signal. Rather than using hard-coded fixed lots—which drift out of proportion as account equity grows or when trading volatile crosses—well-engineered EAs query live broker contract specifications right before order placement.

In MQL5, the most reliable method is OrderCalcProfit(), which computes the exact loss in account currency for 1.00 lot between the proposed entry and stop-loss price while accounting for broker exchange rates and contract multipliers. In MQL4 and tick-based MQL5 routines, EAs divide the monetary risk amount by stopLossTicks × SymbolInfoDouble(_Symbol, SYMBOL_TRADE_TICK_VALUE), then normalize the raw volume to SYMBOL_VOLUME_STEP (typically 0.01) and clamp it within SYMBOL_VOLUME_MIN and SYMBOL_VOLUME_MAX. This is essential for passing prop firm daily drawdown rules without accidental oversizing.

Lot Size Calculator — Frequently Asked Questions

What is the formula for a forex lot size calculator?

Position Size (Lots) = (Account Balance × Risk %) / (Stop Loss in Pips × Pip Value per Standard Lot). For example, risking 1% of a $10,000 balance ($100) with a 25-pip stop loss on EUR/USD ($10 per pip) yields $100 / (25 × $10) = 0.40 standard lots (40,000 units).

How many units are in a standard, mini, micro, and nano lot?

In forex, 1.00 standard lot equals 100,000 base currency units, 0.10 mini lot equals 10,000 units, 0.01 micro lot equals 1,000 units, and 0.001 nano lot equals 100 units. On spot gold (XAU/USD), 1.00 standard lot typically represents 100 troy ounces.

Why does XAU/USD (Gold) lot sizing differ from currency pairs?

Spot gold (XAU/USD) uses a standard contract size of 100 troy ounces rather than 100,000 currency units. At a 0.01 pip increment, 1.00 standard lot moves $1.00 per pip ($100 per $1.00 price move), whereas a 0.01 micro lot moves $0.01 per pip ($1.00 per $1.00 move).

What should I do if the calculator returns less than 0.01 lots?

Most MT4 and MT5 brokers enforce a 0.01 micro-lot minimum order volume. If your calculated size falls below 0.01 lots, opening a minimum trade will risk more than your target percentage. Consider widening your stop loss proportionally, using a cent/nano account if supported, or skipping the setup.

How do MetaTrader Expert Advisors calculate dynamic lot sizes automatically?

MQL4 and MQL5 Expert Advisors compute dynamic lot sizes using AccountInfoDouble(ACCOUNT_EQUITY), SymbolInfoDouble(..., SYMBOL_TRADE_TICK_VALUE), and OrderCalcProfit() in MQL5. The resulting volume is aligned to SYMBOL_VOLUME_STEP and clamped between SYMBOL_VOLUME_MIN and SYMBOL_VOLUME_MAX before order submission.

Risk Disclaimer: Trading leveraged Forex and CFDs carries a high level of risk and may not be suitable for all investors. All guides, calculators, Expert Advisors, and market tools are provided strictly for educational purposes and do not constitute financial advice. Review our full Risk Disclosure before live deployment.

FXAlgoLab (hosted at forexfactory.cc) is an independent algorithmic trading education resource and is not affiliated with, endorsed by, or connected to Forex Factory or Fair Economy, Inc. (forexfactory.com).