Account Protection Manager
Unified account risk guard combining an equity floor, daily loss limit, and peak drawdown limit with safe liquidation, pending-order cancellation, early warnings, and smart unlock controls.
What it does
10 capabilities- Equity floor by fixed amount, percentage of balance, or both
- Daily loss limit by percentage or amount with configurable day-start time and basis
- Peak drawdown limit with equity, balance, or max high-water mark modes
- Proportional withdrawal math prevents false breaches when taking profits or withdrawing
- Optional credit exclusion so bonus credit does not mask real equity losses
- Tagged position liquidation with automatic retry plus pending-order cancellation
- Order-level breach blocking that always permits closing orders
- Early warning threshold with client mail, risk alerts, and CRM reports
- Smart auto-unlock on deposit or new day that never overrides manual bans
- Dry-run audit mode, crash-safe state persistence, and dormant account pruning
How it works
Account Protection Manager combines three account-level protection engines into a single plugin so brokers do not have to coordinate overlapping stop-out plugins. It enforces an equity floor (fixed amount or percentage of balance), a daily loss limit (percentage or amount from a configurable day-start basis and server time), and a peak drawdown limit (percentage or amount from each account's high-water mark). Deposits and withdrawals adjust baselines and peaks mathematically so withdrawing funds or taking profits never causes false breaches. Credit can be included or excluded from effective equity. When a limit is breached, the plugin can liquidate open positions with tagged dealer retries, cancel pending orders, disable trading, block new non-closing orders, notify clients and risk staff, and record structured CRM reports. Early warnings alert before liquidation, dry-run mode audits rules without touching accounts, and automatic unlock on deposit or new-day rollover only re-enables accounts disabled by the plugin itself while never overriding manual compliance bans.
Parameters & options
Configured directly in MetaTrader 5 Administrator and testable live in the simulator.
| Parameter | Type | Default | Description |
|---|---|---|---|
groups | group mask | * | Client groups that are watched (MT5 group mask). * means all |
exclude_logins | text | empty | Comma-separated account logins excluded from protection |
equity_floor | number | 0.00 | Fixed equity floor in the account currency. 0 means off |
equity_floor_percent | number | 0.00 | Equity floor as a percentage of balance. 0 means off |
daily_loss_percent | number | 5.00 | Maximum daily loss as a percentage of the day-start baseline. 0 means off |
daily_loss_amount | number | 0.00 | Maximum daily loss in the account currency. 0 means off |
day_start_time | text | 00:00 | Server time HH:MM when the daily loss period resets |
daily_basis | text | max_balance_equity | Day-start reference basis: balance, equity or max_balance_equity |
max_drawdown_percent | number | 10.00 | Maximum drawdown from peak as a percentage. 0 means off |
max_drawdown_amount | number | 0.00 | Maximum drawdown from peak in the account currency. 0 means off |
peak_mode | text | equity | High-water mark tracking mode: equity, balance or max_balance_equity |
reset_peak_after_stopout | bool | 0 | 1: reset the peak to current equity once positions close after a drawdown stop out |
include_credit | bool | 1 | 1: include bonus credit in effective equity; 0: evaluate equity minus credit |
close_positions | bool | 1 | 1: close all open positions on breach with tagged retry |
cancel_pending_orders | bool | 1 | 1: cancel all pending orders on breach |
disable_trading | bool | 1 | 1: disable trading on breach |
block_orders_on_breach | bool | 1 | 1: reject new non-closing orders while breached (closing orders always pass) |
warn_percent | number | 80.00 | Percentage of daily loss, drawdown or equity budget consumed to emit an early warning. 0 means off |
auto_unlock_on_deposit | bool | 1 | 1: re-enable trading after a deposit if this plugin disabled it and equity rises strictly above all active floors |
notify_client | bool | 1 | 1: send MT5 internal mail to the client on warnings, breaches and unlocks |
notify_risk | bool | 1 | 1: emit risk alerts to the journal and alerts report on warnings and breaches |
dry_run | bool | 0 | 1: log and record breaches without closing positions, cancelling orders, disabling trading or blocking orders |
license_key | text | empty | License key from FXOpsPro, for example FXO-XXXXX-XXXXX-XXXXX-XXXXX-XXXXX |
license_server | text | https://plugins.fxopspro.com | License server address |
dealer_login | int | 0 | Manager login with dealer rights that closes or opens positions for the plugin. 0: the plugin only logs |
Risk management



