MT5 Expert Advisor: 1-Min Breakout with 56-Second Hard Exit & Trailing Balance Drawdown

Şartname

PLATFORM: MetaTrader 5 (MQL5)
ASSET: XAUUSD (Gold)
ACCOUNT TYPE: Live Raw Spread Account (Floating Spread + Commission) 500x leverage
The broker commission is exactly 
3 usd per standart lot per side6.00 round turn). The EA's internal trade tracking, net profit/loss metrics, and trailing drawdown calculations must completely factor in these commission charges alongside the raw asset spread.

I need a clean, optimized Expert Advisor for MT5 based on a 1-minute candle breakout strategy with strict time exits and capital protection.

1. INPUT SETTINGS (User Configurable)
• Target_Risk_Cash: (Fixed dollar amount per trade, e.g., i can control how much i can risk per trade like for example 5$ or 10 or 500 
• SL_Distance_Gold: (Fixed price distance, default 0.94) for example gold entry Price is 4300,50$ the sl is 4299,56$
• Risk_Reward_Ratio: (Default 1.10)
• Max_Daily_Loss_Percent: (Default 45.0)
• Session_1_Start / End: (Default 03:00 / 05:00 EST)
• Session_2_Start / End: (Default 08:00 / 12:00 EST)
 
NOTE ON TIME ZONES: Session inputs must reference the MetaTrader Server Time (TimeCurrent), NOT the user's local PC time. I will manually adjust these hour inputs to match my desired EST windows based on my broker's server clock.
I will 
Check their broker's server time using TimeCurrent() in MT5
Calculate the difference between their desired EST window and server time
Manually adjust the session inputs to match server time
Enter corrected values in the EA's input parameters
The EA should have two trading sessions that i control. I i i will decide when each session starts and ends by entering numbers in the EA settings.
The EA only trades during those times i set
The EA will have four input boxes that you fill in
1. Session 1 Start - When the first trading session begins
2. Session 1 End - When the first trading session ends
3. Session 2 Start - When the second trading session begins
4. Session 2 End - When the second trading session ends
the EA checks what time it is on my broker's server. If the current server time falls between any of the session start and end times, the EA is allowed to trade. If it's outside both sessions, the EA does nothing.
So if i set Session 1 to start at 11 and end at 13, the EA will only look for trades between 11:00 and 12:59 server time. At 13:00 exactly, it stops trading until the next session or the next day.


CORE TRADING LOGIC
• The EA monitors the 1-minute chart.
• Max 1 open trade at any given time. Only trade within the specified session hours.
• BUY ENTRY: If no trade is open, enter a BUY STOP Order the moment current price breaks above the HIGH of the previous completed 1-minute candle (Candle [1]).
• SELL ENTRY: If no trade is open, enter a SELL STOP Order the moment current price breaks below the LOW of the previous completed 1-minute candle (Candle [1]).
• TAKE PROFIT: Calculated using the Risk_Reward_Ratio multiplied by the SL distance. 1.10rr
• STOP LOSS: Fixed at the SL_Distance_Gold (e.g., if entry is 4350.00, SL for Buy is 4349.06).

• LOT SIZING: Must calculate dynamically before entry so that hitting the full SL equals exactly the Target_Risk_Cash amount that i chosed


HARD TIME EXIT (OnTimer execution)
• To ensure speed, please use an OnTimer() loop running every 1000ms.
• If a trade is open and the current server time reaches the 56th second of the minute (e.g., XX:XX:56), the trade must be closed immediately via market order, regardless of profit or loss status.If neither pending order has been triggered by the 56th second, the EA must delete both pending orders for that minute."
If a market position is open, the moment the current server time matches or exceeds the 56th second of the minute (e.g., time.sec >= 56), the position must be closed immediately via a market order, regardless of profit or loss.
Pending Order Cleanup: If neither the Buy Stop nor Sell Stop pending order has been triggered by the 56th second of the minute, the EA must immediately delete both pending orders.


BALANCE-BASED TRAILING DRAWDOWN PROTECTION
Tracking must be based on CLOSED account balance, completely ignoring open floating equity.
At the start of the day, set Peak_Balance = Current Balance.
If account balance increases after a trade closes, Peak_Balance ratchets up to match it.
If account balance decreases after a losing trade, Peak_Balance stays locked at its highest peak.
Calculate the Floor: Hard_Floor = Peak_Balance * (1.0 - (Max_Daily_Loss_Percent 45 / 100.0)).
If the closed account balance ever drops to or below this Hard_Floor, the EA must immediately close any active trade, cancel all pending stop order halt all operations, and block any new trades until the next calendar day.
Track a persistent variable called Peak_Balance. If the closed balance increases, Peak_Balance must ratchet up to match it. If the balance drops, Peak_Balance remains locked at its lifetime highest peak. Crucial: This peak must never automatically reset lower just because a new calendar day starts.
If the closed account balance drops to or below the hard floor wich is 45% of the account like for example the balance is 1000 and it become 550 or less then the EA must immediately close any active trade, delete all pending stop orders, halt all trading operations, and completely block execution until a new calendar day begins AND the user manually resets the EA."


NEWS FILTER INPUTS
• Use_News_Filter: (True/False, Default: True)
• News_Importance_Level: (Enum for MQL5 Calendar Impact: High Only, or High & Medium. Default: High Only)
• Filter_Currency: (Default: "USD")
• Mins_Before_News: (Default: 10)
• Mins_After_News: (Default: 10)
If for example there is high impact news at 14:30
The Block Before The EA must completely block any new trades or pending orders from 14:20 up until 14:30.
The Block After The EA must continue to block any new trades or pending orders after the news until 14:40.



DELIVERABLE: Fully commented source code (.mq5) and compiled file (.ex5).




Yanıtlandı

1
Geliştirici 1
Derecelendirme
(108)
Projeler
176
25%
Arabuluculuk
23
13% / 78%
Süresi dolmuş
16
9%
Çalışıyor
2
Geliştirici 2
Derecelendirme
(19)
Projeler
24
8%
Arabuluculuk
9
33% / 33%
Süresi dolmuş
1
4%
Yüklendi
3
Geliştirici 3
Derecelendirme
(546)
Projeler
830
62%
Arabuluculuk
33
27% / 45%
Süresi dolmuş
23
3%
Çalışıyor
Yayınlandı: 1 kod
4
Geliştirici 4
Derecelendirme
(6)
Projeler
7
71%
Arabuluculuk
0
Süresi dolmuş
0
Çalışıyor
5
Geliştirici 5
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
6
Geliştirici 6
Derecelendirme
(851)
Projeler
1460
72%
Arabuluculuk
122
29% / 48%
Süresi dolmuş
356
24%
Çalışıyor
Yayınlandı: 3 makale
7
Geliştirici 7
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
8
Geliştirici 8
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
9
Geliştirici 9
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
10
Geliştirici 10
Derecelendirme
(6)
Projeler
7
43%
Arabuluculuk
1
0% / 100%
Süresi dolmuş
0
Serbest
11
Geliştirici 11
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
12
Geliştirici 12
Derecelendirme
(365)
Projeler
439
54%
Arabuluculuk
22
50% / 14%
Süresi dolmuş
30
7%
Yüklendi
13
Geliştirici 13
Derecelendirme
(201)
Projeler
260
21%
Arabuluculuk
23
48% / 17%
Süresi dolmuş
0
Yüklendi
14
Geliştirici 14
Derecelendirme
(247)
Projeler
291
76%
Arabuluculuk
13
77% / 0%
Süresi dolmuş
4
1%
Çalışıyor
15
Geliştirici 15
Derecelendirme
(8)
Projeler
8
0%
Arabuluculuk
2
50% / 0%
Süresi dolmuş
1
13%
Çalışıyor
16
Geliştirici 16
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Çalışıyor
Yayınlandı: 1 kod
17
Geliştirici 17
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
18
Geliştirici 18
Derecelendirme
(14)
Projeler
26
42%
Arabuluculuk
3
0% / 67%
Süresi dolmuş
6
23%
Yüklendi
19
Geliştirici 19
Derecelendirme
(52)
Projeler
66
41%
Arabuluculuk
1
0% / 100%
Süresi dolmuş
7
11%
Serbest
20
Geliştirici 20
Derecelendirme
(14)
Projeler
20
25%
Arabuluculuk
0
Süresi dolmuş
2
10%
Serbest
Yayınlandı: 3 kod
21
Geliştirici 21
Derecelendirme
(2671)
Projeler
3404
68%
Arabuluculuk
77
48% / 14%
Süresi dolmuş
342
10%
Serbest
Yayınlandı: 1 kod
22
Geliştirici 22
Derecelendirme
(7)
Projeler
10
10%
Arabuluculuk
4
50% / 0%
Süresi dolmuş
0
Yüklendi
Yayınlandı: 4 makale, 34 kod
23
Geliştirici 23
Derecelendirme
(20)
Projeler
26
38%
Arabuluculuk
6
33% / 50%
Süresi dolmuş
0
Serbest
24
Geliştirici 24
Derecelendirme
(317)
Projeler
564
35%
Arabuluculuk
81
31% / 44%
Süresi dolmuş
204
36%
Serbest
25
Geliştirici 25
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
26
Geliştirici 26
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
27
Geliştirici 27
Derecelendirme
(25)
Projeler
31
13%
Arabuluculuk
13
0% / 77%
Süresi dolmuş
9
29%
Serbest
28
Geliştirici 28
Derecelendirme
(8)
Projeler
9
11%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
29
Geliştirici 29
Derecelendirme
(78)
Projeler
88
31%
Arabuluculuk
9
11% / 56%
Süresi dolmuş
4
5%
Çalışıyor
30
Geliştirici 30
Derecelendirme
(104)
Projeler
127
24%
Arabuluculuk
23
30% / 52%
Süresi dolmuş
8
6%
Serbest
31
Geliştirici 31
Derecelendirme
(12)
Projeler
16
25%
Arabuluculuk
1
0% / 0%
Süresi dolmuş
4
25%
Çalışıyor
32
Geliştirici 32
Derecelendirme
(1)
Projeler
1
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
33
Geliştirici 33
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
34
Geliştirici 34
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
35
Geliştirici 35
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
36
Geliştirici 36
Derecelendirme
(62)
Projeler
90
29%
Arabuluculuk
24
13% / 58%
Süresi dolmuş
7
8%
Çalışıyor
37
Geliştirici 37
Derecelendirme
(38)
Projeler
37
43%
Arabuluculuk
12
17% / 50%
Süresi dolmuş
2
5%
Serbest
38
Geliştirici 38
Derecelendirme
(3)
Projeler
5
20%
Arabuluculuk
1
100% / 0%
Süresi dolmuş
2
40%
Serbest
Benzer siparişler
i need the EA same working on trading view Hikin Ashi chart with same specifications and rules on mt5 Rules as per in script is available when applied on chart need to check on Hikin Ashi chart 1. Buy trade when purple candle closed above last any black candle high on Hikin Ashi & avoid long abnormal candle & if market makes more than 20-30 candles without changing the color 2. Buy when purple candle close above its
I have my own strategy in 1min. I want it convert to a bot. Please reach me only coding experts. I dont want bit makers from Ai. Demo version should be provided for confirmation
🔍 Strategy Logic 📌 Indicators Used 21 EMA RSI (Upper Level: 61, Lower Level: 39 – Customizable) 📈 Buy Side Setup (Long Entry) Step 1 – Trend Confirmation A Green candle must close above 21 EMA. Step 2 – Pattern Formation After the green candle, observe next 4 candles. At least one Red candle must form (opposite candle). That Red candle must also close above EMA. Step 3 – Key Level Marking Mark the High of the Red
Expert Advisor (EA) Requirements – MT5 (MQL5) Project Overview Develop an automated Expert Advisor (EA) for MetaTrader 5 based on EMA crossover signals combined with strict risk management and trade management principles. The EA must be optimized for Forex pairs and indices and should operate automatically without manual intervention. Entry Conditions Buy Setup Fast EMA crosses above Slow EMA. Current candle closes
MT5 Expert Advisor Development Project Overview I am looking for an experienced MQL5 developer to build a custom MetaTrader 5 Expert Advisor based on a grid-cycle trading framework. This is not a standard grid EA . The system combines: Session-based trade initiation Multi-filter signal generation Dynamic grid management Advanced basket management State-machine-driven trade lifecycle management Dynamic take-profit
Need an MT5 EA coded in MQL5. Strategy uses internally calculated MT5 Heikin Ashi candles, EMA 9 and EMA 21 on M1 USDJPY. Fixed lot size 12.20. One trade at a time. 40-point stop loss. Exit after 3 consecutive opposite Heikin Ashi candles. I have a detailed strategy document and video examples of valid and invalid entries. Videos linked show MT5 IOS but custom EA code will be used for windows MT5
I require a custom EA and an accompanying custom indicator built in MQL5 for Meta Trader 4/5. The EA must be fully automated (Algo Trading); Telegram-Signal-Linked and named 'AMK Fx'
Use the H4 timeframe to determine the main trend direction. Identify valid order blocks on the H1 timeframe. Identify liquidity zones and liquidity sweeps. Wait for M15 confirmation before opening a trade. Only take buy trades in bullish market conditions and sell trades in bearish market conditions. Risk a fixed percentage of account balance per trade (user adjustable). Automatically calculate lot size based on
MC Trader's 30+ USD
If Buy: it must Buy when a conformation is done Bye the candle that would be a bullish engolfing candle or after liqudity swip or when sellers has stepped down the market and the market regains energy and trand upwards, it's stop loss must be below the Buy position and it's take profit must be at the top of all candles
Hello, I'm looking for an expert who can help me acquire a secure, easy-to-use bot with Turkish language support for automated buying and selling in Forex, commodities, and cryptocurrencies, and who can also teach me how to set it up and use it

Proje bilgisi

Bütçe
70 - 90 USD
Son teslim tarihi
from 2 to 5 gün

Müşteri

Verilmiş siparişler1
Arabuluculuk sayısı0