Ultimate Forge UTS is a fully automated Expert Advisor for the MetaTrader 5 platform, designed specifically for trading XAUUSD (gold). It operates on disciplined entry timing combined with smart, automatically adapting position management.
Symbol
XAUUSD
Gold spot
Platform
MT5
MetaTrader 5
Min Balance
$1,000
$2,000+ recommended
Mode
Auto
Set & forget
Key features:
Fully automated trading with no manual intervention required
Adaptive logic that adjusts to gold's current price level
Live on-chart visuals — control panel, target line, and close bracket overlay
Multiple risk modes — Fixed, Low, Medium, and High
Built-in risk controls — daily and overall drawdown limits, weekend pause, Friday close
Crash-safe state — open cycles survive terminal restarts seamlessly
02Quick Setup
Copy UltimateForgeUTS.ex5 to your MT5 terminal's MQL5/Experts folder
Restart MT5 or refresh the Navigator panel
Open a XAUUSD chart on any timeframe
Drag Ultimate Forge UTS onto the chart
Make sure Allow algorithmic trading is checked
Click OK to accept the default settings
The control panel appears in the upper-left of the chart and the chart theme switches to the Forge style
The default settings are pre-tuned for current gold market conditions. We recommend running on a VPS for live trading to ensure 24/5 uptime.
03The Control Panel
When the EA is attached to a chart, a custom Forge panel appears in the upper-left and the chart theme switches to the dark Forge style.
FIG. 1 — The Forge Panel + Chart Theme
Live control panel with trading state, position details, drawdown, and quick-action buttons.
01Status — Current trading state (engaged, in-trade, cooldown, paused, etc.)
02Direction — Current trend bias (Up / Down / Flat)
03Mode & Bars Held — Active trading mode and elapsed time since the cycle began
04Buys section — Open buy positions, total lots, live cycle P/L, and bars held
05Sells section — Same metrics for sells (disabled by default)
06Day Total — Today's realized P&L in dollars and percentage
07Forge DD — Live drawdown from running peak
08Action Buttons — Disable trading, close all buys, close all sells, and ADD RECOVERY (open a manual grid add bypassing entry filters)
Manual Recovery Button
The ADD RECOVERY button on the panel opens a new position immediately, bypassing the entry trigger, session filter, and cooldown logic. Use it when you want to manually press an open cycle further into the basket — for example to average down a deep cycle ahead of an expected reversal.
Direction — picks BUY or SELL based on your currently open positions (the majority side wins). With no positions open, falls back to the current trend bias.
Lot size — uses your base lot, scaled by your Per-Position Lot Scaling settings (see Risk Modes) based on how many positions are already open.
Safety — margin and market-open are still checked; only the entry filters are bypassed.
Manual recovery adds risk to an already-open cycle. Use deliberately, not as a habit, and only when you have a specific read on the market that the EA's filters can't see.
04The Close Bracket
When a position cycle is open, Ultimate Forge UTS draws a four-line bracket on the chart that pinpoints the price and time of the next planned close. This unique visual lets you see at a glance exactly when and where the EA is about to exit.
TPTop horizontal — Target price line, including swap and commission
●Target dot — Marker at the corner where the target price meets close-time
The bracket changes color based on cycle state:
Gray — armed (price still below target)
Amber — locked (target met but waiting briefly)
Bright cyan — pending close (will fire imminently)
A countdown near the target dot shows seconds until the planned close.
05Risk Modes
The EA offers four position-sizing modes. All modes use the same trading logic — only lot size differs.
Mode
Behavior
Best For
Fixed
Constant lot size regardless of balance
Conservative traders, predictable risk
Low
Lots scale with balance, conservative ratio
Compounding with balanced risk
Medium
Lots scale with balance, moderate ratio
Faster compounding, more drawdown
High
Lots scale with balance, aggressive ratio
Experienced traders only
Higher risk modes scale both profits AND drawdown proportionally. Higher modes can experience peak equity drawdowns of 25–70% before recovery. Choose conservatively if you are new to automated grid-style EAs.
Per-Position Lot Scaling
From v2.20 onward, Ultimate Forge UTS supports optional per-position lot scaling for grid adds. When enabled, each additional grid position uses a larger lot than the previous one — useful for aggressive recovery profiles. This feature is off by default.
Input
Purpose
InpUseLotScaling
Master toggle. false by default — base lot is used for every add.
InpLotScaleMode
ADD = step is added to lot each position (linear). MULT = lot is multiplied by step each position (exponential / martingale-style).
InpLotScaleStep
ADD mode: lots added per position (e.g. 0.01 → 0.01, 0.02, 0.03 …). MULT mode: multiplier per position (e.g. 2.0 → 0.01, 0.02, 0.04 …).
Scaling applies to grid adds on top of the base position. The first position always uses the base lot from your Risk Mode. InpMaxLot caps every position, and the broker's volume step still floor-rounds the result.
MULT mode compounds quickly and can hit your max-lot cap or margin limits within a few adds. Test thoroughly in Strategy Tester before running live.
06Trading Sessions
Ultimate Forge UTS only opens new positions during pre-configured time windows. These are tuned around the most liquid and predictable parts of the gold trading day. Outside of these windows the EA stays flat (it continues to manage any open cycle until it closes normally).
All times are broker server time, which is typically GMT+2/+3 for most MT5 brokers. Check your broker's server time if you want to convert to your local clock.
Session
Window
Coverage
Session 1
02:00 – 05:00
London open / European morning liquidity
Session 2
18:00 – 20:00
New York afternoon momentum
Session 3
21:00 – 24:00
NY close to Asia open overlap
Session 4
disabled
Available as an optional extra window
Friday Behavior
No new trades after Friday 18:00 server time, to avoid carrying fresh positions into the weekend close.
Existing open cycles continue to be managed and will close normally on their own targets.
Force-close at weekend is available but disabled by default. Enable InpFridayClose with an hour in InpFridayCloseHr if you want all positions flattened before the close.
The default schedule is optimized for the dominant XAUUSD volatility windows. If your broker runs on a non-standard server timezone, adjust InpSession1Start through InpSession4End in the SESSION & TIME FILTER input group to align with your local trading session map.
Disabling the Session Filter
Set InpUseSessionFilter to false if you want the EA to evaluate entries 24 hours a day. This is not recommended in production — the default windows materially reduce drawdown by skipping low-quality price action during illiquid hours.
07Performance Profile
The chart below illustrates the typical equity-curve shape produced by Ultimate Forge UTS over a multi-year backtest using Fixed lot mode with default settings.
FIG. 2 — Equity Curve Profile (Illustrative)
Typical balance growth shape with characteristic drawdown spikes during open cycles. Specific results depend on broker conditions, lot mode, and market regime.
Performance characteristics:
High overall win rate on closed cycles
Smooth balance progression with cycle-driven drawdown spikes
Strong recovery factor — drawdowns typically resolve to new highs
Trade activity concentrated in optimal market hours
Live results depend on your broker's tick data quality, spread, swap rates, and execution model. Performance can vary by 15–30% depending on broker conditions. Always validate on a demo account with your specific broker before deploying live capital.
08Tips & Best Practices
VPS recommended — for 24/5 uptime, run on a low-latency VPS near your broker's server.
Start with Fixed mode — get comfortable with the EA's behavior before exploring dynamic risk modes.
Watch the Close Bracket — the bright cyan target dot shows exactly when the next exit will fire. Don't second-guess imminent closes.
Spread matters — tight broker spreads on XAUUSD significantly improve net performance. Avoid brokers with markup spreads.
Allow time for cycles to complete — most cycles complete in minutes to hours. This is normal and by design.
09FAQ
Why does the EA wait to close after price crosses the target line?
Closes are scheduled to fire at controlled exit moments to ensure clean execution. The EA also respects a brief stabilization window after entry. Both behaviors are by design and produce better long-term results than instant closes on tiny gains.
Why aren't entries firing in this market?
Entries require multiple conditions to align — direction bias, market timing, and signal quality. Outside optimal conditions, the EA correctly stays flat. Patience pays off in automated trading.
What if a cycle stays open for a long time?
Rarely, a cycle may hold for an extended period if it opens just before a major price decline. The cycle will eventually close in profit when price retraces. You can manually close such positions via the panel buttons if needed.
Can I change settings while the EA is running?
Yes. Right-click the EA on the chart, select Properties, modify settings, and click OK. Changes take effect immediately.
What happens if my terminal restarts?
The EA saves state to disk on critical events. On terminal restart, it reads the saved state and resumes seamlessly. Open positions continue to be managed.
Can I run this on multiple charts or accounts?
Yes. Each instance manages its own cycle independently. Use a unique magic number per account to avoid conflicts if multiple instances are running on the same broker.
10Disclaimer
Past performance does not guarantee future results. Forex and CFD trading involves substantial risk of loss and is not suitable for every investor. The performance characteristics described in this manual were observed in historical backtests on specific broker conditions and may differ from your live trading experience. Only trade with capital you can afford to lose. Use of this Expert Advisor implies acceptance of all associated risks.