How to Automate a Kill Switch That Flattens All Accounts When Daily Loss Is Hit
A single-button panic close is useful. An automatic one that triggers before you can override it is better. Here's how to set up a kill switch across all your prop accounts.
How to Automate a Kill Switch That Flattens All Accounts When Daily Loss Is Hit
A kill switch is the last line of defense in a prop trading operation. Not the first — you have daily loss limits, drawdown monitoring, and position size controls before it gets there. But when everything else fails or gets overridden by the worst version of you (the one who's down $900 and convinced the next trade will fix it), a kill switch that triggers automatically and can't be easily overridden is what stands between a bad session and a blown account.
Two Types of Kill Switches
Manual Kill Switch
A button or hotkey that closes all positions across all accounts immediately when pressed. NinjaTrader has a native "Close All Positions" function, and you can add it as a keyboard shortcut. It's useful but relies on you pressing it — which is exactly the moment your judgment is most compromised.
Automated Kill Switch
A rule that triggers without your input. When daily loss on any account reaches a configured threshold, the system automatically flattens that account and locks it — no confirmation required, no override window. This is the version worth setting up.
Setting Up Automated Kill Switch via Copilink
Copilink's daily loss limit feature is effectively an automated kill switch per account. When configured:
- Set a daily loss threshold for each follower account (e.g., $850 on a $1,000 limit account — slightly inside the firm's official limit)
- When realized losses hit that threshold during a session, Copilink automatically:
- Sends a flatten order to close all open positions on that account
- Locks the account — no new orders from the copier will execute on it for the remainder of the session
- Sends an alert so you're aware of what happened
- Other accounts continue trading normally — the lockout is per-account, not global
The kill switch is local to NinjaTrader — it doesn't require a cloud server to process the trigger, so there's no latency between the threshold being hit and the flatten order going out.
Global Kill Switch: Flatten Everything at Once
For situations where you want to close all positions across all accounts simultaneously — market structure breaks down suddenly, you need to step away, or something goes wrong with your setup — you can configure a global kill trigger.
In Copilink, this can be triggered by:
- A configurable hotkey that sends flatten orders to all follower accounts simultaneously
- A global daily loss threshold — if your combined P&L across all accounts hits a configured floor, everything flattens
The global flatten is useful for correlated risk scenarios. If the market has an extreme move (flash crash, geopolitical event mid-session), all your accounts are correlated — they'll all be moving against you simultaneously. Being able to flatten everything with one trigger, rather than closing accounts one by one, limits how much the move costs you.
Setting the Right Trigger Thresholds
Per-account triggers: Set at 85-90% of the firm's official daily loss limit. This gives you a small buffer for execution slippage when the flatten order goes out — you want the account to close cleanly inside the official limit, not at it.
Global trigger: Think about this in terms of what a "bad day across all accounts" looks like for your portfolio. If running 10 funded accounts, a global trigger at 60-70% of your combined daily loss capacity might be appropriate — capturing the scenario where correlated losses are significant enough to warrant a full stop.
Account lock duration: Configure the lockout to last until manually reset by you — not just until end of session. Some traders have their kill switch trigger and then start re-entering trades on locked accounts after they reset the lock. The point of the kill switch is that today is done when it triggers.
Testing the Kill Switch Before You Need It
Run a test in a simulated environment before relying on this in live trading. Confirm that:
- The flatten order executes and closes all positions correctly
- The account lock prevents new orders from going through
- The alert fires so you know the trigger activated
- Other accounts are not affected when a single account triggers
Set up the full risk management configuration — including kill switch — for your funded accounts at copilink.com.
Related Articles
NinjaTrader Crashed During a Live Session — Exact Recovery Steps for Prop Accounts
4 min readFrom Sim to Live: How to Transition Your Trade Copier Setup When You Pass Your Evaluation
4 min readTradingView Webhooks Into NinjaTrader: What's Possible and What's Allowed on Prop Accounts
4 min readReady to Start Trade Copying?
Try Copilink free for 7 days. No credit card required. Copy trades across unlimited prop firm accounts.