
Gold
A focused improvement
For a specific change to an existing project.
Quoted per project
Discuss this tier · GoldWith the source in your hands, your ideas can go further than the settings panel.
Open your source in MetaEditor and start building. Projects use self-contained code or the standard libraries already included with MT5.
Study, customise and trade on your own accounts. Your EA source gives you the freedom to keep refining your ideas.
One purchase per source project. MQLume does not charge by the number of activations or uses.
Bring your ideas to an AI coding assistant. Use the editable MQL5 project as your starting point, and stay in control of every change.
Ask for a session filter, clearer logging or a different risk rule.
Read the proposed code, check the logic and compile it in MetaEditor.
Compare backtests, then test on a demo account before considering live use.
Use an AI tool of your choice; no AI subscription is included. Review generated code and keep your source private. Better tools support your process, but do not guarantee trading profits.
Overview
The source edition includes a single English MQ5, the compiled EX5, README and a guide to all 38 input fields. Study the pending-order workflow, adapt the code and compile your own version. Classic Signal 2 is the default, with Classic Signal 1 and Standard Signal 3 also available. The Command Hub and two-way Radar show account, market and order information. Use the product Help page and PARAMETERS.pdf to get started; no preset file or external model is included or required.
Built for MetaTrader 5. A complete source project, clear inputs and practical documentation give you control over your next build.
Trading setup
Explore gold breakout entries from H2 pivots, with selectable signal presets, adjustable sizing and trailing protection in editable MT5 source.
Setup information follows the supplied guides. The chart timeframe does not replace the internal H2/M30 calculations; AUTO clock calibration needs M5 history. Confirm your broker’s symbol and account conditions.
Explore 50 lines of the project's MQL5 source. Scroll inside the editor to discover more.
double PriceScale() { double middle=(bid+ask)*0.5; return middle>0 && pip>0 ? middle/(pip*100.0) : 1.0; }double EntryOffset(bool buy) { double coefficient=buy ? -0.0287 : -0.0516; return (PriceScale()*coefficient+(double)InpPendOffsetPts)*(buy?1.0:-1.0)*pip; }int VolumeDigits() { double scaled=NormalizeDouble(volumeStep,8); for(int d=0;d<8;d++) { if(MathAbs(scaled-MathRound(scaled))<=1e-8) return d; scaled=NormalizeDouble(scaled*10.0,8); } return 8; }double FloorVolume(double volume) { if(volumeStep<=0) return volume; return NormalizeDouble(MathFloor(volume/volumeStep+1e-8)*volumeStep,VolumeDigits()); }bool ValidVolume(double volume) { if(volume<minimumVolume || volume>maximumVolume || volumeStep<=0) return false; double rounded=NormalizeDouble(MathRound(volume/volumeStep)*volumeStep,8); if(MathAbs(rounded-volume)>volumeStep*0.1) return false; long limit=AccountInfoInteger(ACCOUNT_LIMIT_ORDERS); return limit<1 || OrdersTotal()<limit; }// Session information is cached by server minute, as it is independent of quotes.bool InBrokerSession() { static long minute=-1; static bool allowed=true; datetime now=TimeCurrent(); if((long)now/60==minute) return allowed; minute=(long)now/60; allowed=false; if(SymbolInfoInteger(_Symbol,SYMBOL_TRADE_MODE)==SYMBOL_TRADE_MODE_DISABLED) return false; MqlDateTime d; TimeToStruct(now,d); int seconds=d.hour*3600+d.min*60+d.sec; for(uint i=0;i<5;i++) { datetime from,to; if(!SymbolInfoSessionTrade(_Symbol,(ENUM_DAY_OF_WEEK)d.day_of_week,i,from,to)) break; if(seconds>=from && seconds<to) { allowed=true; break; } } return allowed; }Your next build starts here.
Complete source, practical documentation and reference files to help you understand, customise and test your EA.
100% source code means the editable implementation of this product is supplied in full. It is not an EX5-only delivery or a hidden strategy module.
Version 2.3 · Personal-use licenceThe compiled EA accompanying the source. Recompile after editing the MQ5.
Complete, editable single-file source. Read the logic, customise it and compile your own EA.
Guide to all 38 fields, including defaults, preset and custom exits, price units, sizing, clock calibration, news and restart behavior.
A concise welcome, installation and compilation guide, with licence terms and support details.
Testing
Use the guide to understand each preset, then compare the settings and operating modes you intend to use.
Version v2.3 · 38
Initial settings from the delivered source. Review and test changes before using them.
Explore the inputs below to shape the EA around your research, risk preferences and workflow. Outgoing EA order comments use @MQLume and retain required strategy identifiers. Comment inputs remain for saved-setting compatibility and do not remove the execution label.
Read PARAMETERS.pdf alongside README.txt for the meaning, defaults and operating notes behind the short input labels.
Read the supplied parameter guide for units and interactions before changing these initial values.
| Source input key | Initial value |
|---|---|
Gold Snap OfficialNoticeInp_OfficialNotice | Display text |
---___99___ | Display text |
Display only___0___ | Display text |
Read the supplied parameter guide for units and interactions before changing these initial values.
| Source input key | Initial value |
|---|---|
Strategy presetInpStrategyVersion | Classic - Signal 2CLASSIC_SIGNAL_2 |
Magic number (use a unique value per EA)InpMagic | 2698 |
Order comment display (requests use @MQLume)InpTag | Display text |
Max spread: 1 = 0.01 price, 500 = 5.00InpMaxSpread | 500.0 |
Pivot price tolerance (0 = original, 0.05 = 5 cents on gold)InpPivotTolerance | 0.15 |
Pending entry offset: 1 = 0.01 price; + = buy higher / sell lowInpPendOffsetPts | 0 |
Trade only XAUUSD/GOLD symbolsInpGoldOnly | true |
Read the supplied parameter guide for units and interactions before changing these initial values.
| Source input key | Initial value |
|---|---|
Lot sizing method (default: match preset)InpLotMethod | LOT_MATCH |
Fixed lot size (Fixed Lot Size only)InpLotFixed | 0.01 |
Risk percent (Risk % Per Trade only)InpRiskPct | 2.0 |
Max lot per order (0 = broker max)InpMaxLot | 0.0 |
Max drawdown percent (0 = off)InpMaxDD | 0.0 |
Read the supplied parameter guide for units and interactions before changing these initial values.
| Source input key | Initial value |
|---|---|
Exit management sourceInpExitSource | Match strategy presetEXIT_PRESET |
[Custom exit] Same-side cooldown, min (0 = off)InpSLCool | 0 |
[Custom exit] Trailing update interval, sec (0 = no limit)InpTSLGapSec | 50 |
[Custom exit] Min trailing move: 1 = 0.01 price (0 = broker minInpTSLStep | 160.0 |
[Custom exit] SL: 1 = 0.01 price; + = wider, - = tighterInpSLOffsetPts | 0 |
[Custom exit] TP: 1 = 0.01 price; + = farther, - = closerInpTPOffsetPts | 0 |
[Custom exit] TSL: 1 = 0.01 price; + = looser, - = tighterInpTSLOffsetPts | -25 |
Read the supplied parameter guide for units and interactions before changing these initial values.
| Source input key | Initial value |
|---|---|
Enable Friday protectionInpFridayCloseOn | false |
Friday stop new pending orders hour (server time, 0-23)InpFridayStopHour | 19 |
Friday close hour (broker server time, 0-23)InpFridayCloseHour | 23 |
Friday close minute (0-59)InpFridayCloseMinute | 0 |
Read the supplied parameter guide for units and interactions before changing these initial values.
| Source input key | Initial value |
|---|---|
Enable news filter (live/demo only)InpNewsOn | false |
Minimum news importanceInpNewsImportance | NEWS_HIGH |
News currencies (comma-separated, e.g. USD,EUR)InpNewsCurrencies | "USD" |
Stop new pending orders minutes before newsInpNewsPre | 60 |
Resume new pending orders minutes after newsInpNewsPost | 30 |
Delete EA pending orders (news filter ON only)InpNewsClear | true |
Read the supplied parameter guide for units and interactions before changing these initial values.
| Source input key | Initial value |
|---|---|
Clock for the session filterInpClockMode | CLOCK_AUTO |
[AUTO] Trading days of M5 bars scanned for the daily breakInpClockScanDays | 5 |
---___7___ | Display text |
Show info panelInpHUD | true |
Draw boundary linesInpBounds | true |
Switch chart to H2 on loadInpAutoSwitchH2 | false |
Support after delivery
While the product is actively maintained, we investigate and fix reproducible defects in the delivered, unmodified code that conflict with the product description.
Missing files, incorrect delivery and original-code compilation failures in the stated environment.
Provide the release, settings, logs and reproduction steps so we can assess and resolve the issue.
Start with the included guide and contact us for help with delivery or reproducible software defects. Trading results are not guaranteed.
You may read, modify and compile the delivered source for your own research and trading accounts. Keep a backup of the original delivery before making changes. You may not resell, redistribute, publish or sublicense the source or compiled files, or offer them as a white-label product, without separate written permission. Source delivery does not transfer copyright or ownership of third-party names.
Source code is a copyable digital product. Once delivered, we do not accept change-of-mind refunds, including because you no longer need the product. Check compatibility, contents and disclosed limits before ordering.
After payment is verified, we deliver the source package and documentation to your order email. Check your inbox and spam folder. Keep your order reference for delivery and support questions. Include your order reference, source release, terminal build, settings, expected behaviour and steps to reproduce. Attach only relevant logs and remove account credentials.
Read the files, environment and terms
Check the source version and purchase terms
Payment is checked with the provider or on the selected blockchain
Fast, automatic delivery after payment confirmation. No waiting for manual dispatch.
Ask us about advanced custom development. Share your requirements through private support or email; we will discuss the scope and quote separately.
100% committed to following up on your delivery and support requests.
Explore free EA source code




Free editable gold breakout project with six independently selectable cores, session filters and flexible position sizing.

Free editable source with compiled EX5: four gold breakout engines with independent profiles, sizing, direction and exits.

Trend-based entries with optional grid additions, side controls and virtual exits.

RSI entries with two ATR filters, configurable sessions and optional grid management.
Learn the difference: MQL4 / MQL5 source uses .mq4 / .mq5; EX4 / EX5 files are compiled programs. Buying an EX4 or EX5 file does not automatically include source code.
Two original, non-trading learning samples for MT4 and MT5. Inspect OnInit and OnDeinit logging without order execution.
Learning samples only. Review and compile them in MetaEditor before use; these samples do not place trades.
Ready for another approach? Choose an EA to run, or source code to explore and customise.

Source code · MQ5 + EX5
Explore gold pending-entry strategies with adaptive portfolio selection, partial closes and trailing controls.

Source code · MQ5 + EX5
XAUUSD · M1 scalping and flexible sizing

EA only · EX5
Explore gold trading with a single-profile mode, an optional two-profile mode and separate risk inputs.

Free EA · MQ5 + EX5
Free editable source with compiled EX5: four gold breakout engines with independent profiles, sizing, direction and exits.
Loading…
Stay close to MQLume, wherever you like to learn.
See our EAs in action. Explore backtests, walkthroughs and practical guides.
Watch on YouTubeMeet other EA users, share ideas and keep up with what’s new.
Join the community Follow official updates