Drowdown based ea to monitor and prevent from drowdowning

Tarea técnica

Development of Guardian Trading Bot for MT4/MT5


What I need:

A simple protective trading bot (EA) that monitors the entire trading account and automatically closes all positions when specific profit/loss or drawdown conditions are met.


Required Features:

 Monitor all open positions:

  • The bot must track all active positions, regardless of whether they were opened manually or by another Expert Advisor (EA).

Automatic closing of all positions (Option 1):

  • When total profit reaches a specified value (e.g. +€30), the bot must close all active trades.
    → I need a trailing profit feature where I can define a trailing step (e.g. +€5).
  • When total loss reaches a specified value (e.g. -€50), the bot must also close all trades.
    → I also want a trailing stop loss option, where I can define a trailing step (e.g. -€10).

Block new trades after closure:

  • Once the bot closes all trades, it must block any new trades from being opened — especially from other EAs — to prevent immediate re-entry.

Option 2: Daily Drawdown Reset (should be optional and configurable)

Daily account protection with two safety levels:

  • Every day at midnight (or at a custom-defined time), the bot records the current account balance.
  • From that point, it calculates two drawdown thresholds:
    1. First warning level (e.g. -€200)
    2. Second critical level (e.g. -€500)

 Example of how it works:

  • If the balance at 00:00 is €10,000:
    • First level = €9,800
    • Second level = €9,500
  • If the next day at 00:00 the balance is €10,200:
    • New first level = €10,000
    • New second level = €9,700
  • The bot will always protect the highest daily balance, minus the configured drawdown values.

💡Additional logic when limits are triggered:

  • If the first level (e.g. -€200) is reached:
    • The bot closes all currently open positions (both positive and negative).
    • It allows previously set manual orders (pending orders) to remain.
    • It disables all EAs to prevent any further auto-trading.
  • If the second level (e.g. -€500) is reached:
    • The bot closes all positions and all pending orders.
    • It completely shuts down all further activity, both manual and automated.

Bot Settings Required:

  • Take Profit value (in EUR/USD)
  • Daily Stop Loss / Drawdown (in EUR/USD)
  • Daily reset time (with UTC offset configuration)
  • Trailing profit/loss step (in EUR/USD)

 


Han respondido

1
Desarrollador 1
Evaluación
(2)
Proyectos
3
0%
Arbitraje
8
13% / 88%
Caducado
1
33%
Libre
2
Desarrollador 2
Evaluación
(16)
Proyectos
35
23%
Arbitraje
4
0% / 50%
Caducado
2
6%
Trabaja
3
Desarrollador 3
Evaluación
(325)
Proyectos
505
19%
Arbitraje
32
44% / 31%
Caducado
34
7%
Trabajando
4
Desarrollador 4
Evaluación
(22)
Proyectos
24
71%
Arbitraje
1
0% / 0%
Caducado
0
Trabaja
5
Desarrollador 5
Evaluación
(278)
Proyectos
373
72%
Arbitraje
18
33% / 44%
Caducado
14
4%
Trabaja
Ha publicado: 14 ejemplos
6
Desarrollador 6
Evaluación
(21)
Proyectos
28
4%
Arbitraje
4
25% / 0%
Caducado
3
11%
Trabaja
7
Desarrollador 7
Evaluación
(32)
Proyectos
35
34%
Arbitraje
5
0% / 80%
Caducado
0
Trabaja
Ha publicado: 2 ejemplos
8
Desarrollador 8
Evaluación
(1)
Proyectos
4
0%
Arbitraje
5
20% / 40%
Caducado
2
50%
Libre
9
Desarrollador 9
Evaluación
(7)
Proyectos
7
29%
Arbitraje
0
Caducado
0
Trabaja
10
Desarrollador 10
Evaluación
(159)
Proyectos
284
35%
Arbitraje
18
22% / 61%
Caducado
42
15%
Trabajando
11
Desarrollador 11
Evaluación
(1)
Proyectos
1
0%
Arbitraje
0
Caducado
0
Libre
12
Desarrollador 12
Evaluación
(4)
Proyectos
3
33%
Arbitraje
2
0% / 100%
Caducado
0
Libre
13
Desarrollador 13
Evaluación
(51)
Proyectos
69
35%
Arbitraje
4
25% / 75%
Caducado
0
Libre
14
Desarrollador 14
Evaluación
(10)
Proyectos
19
42%
Arbitraje
6
0% / 50%
Caducado
3
16%
Trabaja
15
Desarrollador 15
Evaluación
(501)
Proyectos
968
74%
Arbitraje
27
19% / 67%
Caducado
100
10%
Trabajando
Ha publicado: 1 artículo, 6 ejemplos
16
Desarrollador 16
Evaluación
(39)
Proyectos
57
18%
Arbitraje
6
33% / 17%
Caducado
1
2%
Libre
Ha publicado: 2 ejemplos
17
Desarrollador 17
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
18
Desarrollador 18
Evaluación
(4)
Proyectos
4
0%
Arbitraje
1
0% / 100%
Caducado
0
Libre
19
Desarrollador 19
Evaluación
(250)
Proyectos
460
26%
Arbitraje
140
20% / 59%
Caducado
100
22%
Trabaja
20
Desarrollador 20
Evaluación
(45)
Proyectos
46
24%
Arbitraje
34
9% / 85%
Caducado
10
22%
Libre
21
Desarrollador 21
Evaluación
(1)
Proyectos
1
0%
Arbitraje
1
0% / 100%
Caducado
0
Libre
22
Desarrollador 22
Evaluación
(6)
Proyectos
5
0%
Arbitraje
2
50% / 50%
Caducado
2
40%
Libre
23
Desarrollador 23
Evaluación
(11)
Proyectos
15
13%
Arbitraje
4
25% / 25%
Caducado
4
27%
Trabajando
24
Desarrollador 24
Evaluación
(295)
Proyectos
472
40%
Arbitraje
103
40% / 23%
Caducado
78
17%
Ocupado
Ha publicado: 2 ejemplos
25
Desarrollador 25
Evaluación
(177)
Proyectos
229
20%
Arbitraje
20
40% / 20%
Caducado
0
Ocupado
26
Desarrollador 26
Evaluación
(6)
Proyectos
6
0%
Arbitraje
0
Caducado
2
33%
Libre
27
Desarrollador 27
Evaluación
(250)
Proyectos
256
30%
Arbitraje
0
Caducado
3
1%
Libre
Ha publicado: 2 ejemplos
28
Desarrollador 28
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
29
Desarrollador 29
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
Solicitudes similares
I am building a professional-grade survival EA for USDJPY designed to: Repeatedly pass FTMO-style challenges Sustain long-term funded accounts Deploy safely across multiple prop accounts This is not a retail scalper. This is a controlled EMA pullback engine with strict risk governance and anti-correlation logic . All parameters must be configurable. Defaults must match exactly as listed. Core Strategy – EMA Pullback
I’m after someone to make me a forex ex for meta trader 5 it will be trading GBPUSD only but having to align with EURUSD and rules and entry’s based off weekly and daily vwap with 20 EMA
Key Requirements: ​ Zone Detection: The EA must read "Weak Support/Resistance" zones generated by my indicator (I will provide the .mq4/ex4 file). ​ Execution Logic: - Identify the candle with the longest wick within the detected liquidity zone. ​Place a Pending Order (Buy Stop/Sell Stop) 20 points (2 pips) before the breakout level of that wick. ​ Trade Management: ​Fixed SL: 40 points (4 pips). ​Fixed TP: 40 points
I have a open source Tradingview indicator that I want it to be converted to Ninja Trader8. I have attached it. Please let me know, if you can do it and for how muc
I need help in modifying an amibroker AFL indicator the indicator already works but I need per symbol static variable isolation, parameters persistence per symbol after restart, non declining trailing stop logic, parameter auto restore when switching symbols and a global reset function for static variables. For better understanding As discussed, this is the official offer for restructuring my RAD Chandelier stop loss
Hi, I have a clear MT5 EA wrapper project with locked TSCEA, requiring enhanced execution logic (“pending OR better market” order handling). I can share detailed spec. Please let me know your availability and quote range. Thanks, Tom Pike ------------------------------------------------------------------------------------------------------------------------------ Title: MT5 Wrapper EA – “Limit Order OR Better
ICT_OneTrade_2R 100 - 200 USD
🔥 ICT_OneTrade_2R Precision. Discipline. Consistency. ICT_OneTrade_2R is a professional Expert Advisor designed for traders who value structured execution and controlled risk. This system is built around a fixed Risk-to-Reward ratio of 1:2 (RR 2.0) — meaning every trade is planned with precision: Risk 1 → Target 2. No randomness. No overtrading. Just one high-quality trade per session. ⚙️ Key Features ✔ Fixed RR 1:2
​ Description: I am looking for a professional MQL4 developer/quant trader with a proven track record in EA optimization. This project involves optimizing a third-party EA that currently has a 2-year live track record. ​ The Task: ​ In-Sample Optimization: Optimize the EA parameters using historical data prior to January 1, 2024. ​ Out-of-Sample (Walk-Forward): Validate the optimized settings against the period of
Hi , I have some indicators that I want set up on my TV chart and want to create one chart for some and another chart for some others. Plus I want to set up the brackets orders so I can trade from the chart. I have these set up somewhat but need it cleaned up and the way I want them. how much would something like this cost to do? I'm in California and would like you to show me so I can learn to do this when I want to
Apply with a keen sense of responsibility . Copy the code . Both of my expert has sufficient materials . Its a simple winning strategy , therefore please be ahead of time . Code BLUE . Changing The Strategy According to what i think is correct

Información sobre el proyecto

Presupuesto
30+ USD