Daily loss limit in NinjaTrader 8: what a guard has to do

A daily loss limit only protects you if something enforces it before your firm does, and enforcing means measuring the right number, acting on it, and staying out of the way of a good day.

A daily loss limit is a number until something enforces it. The firm enforces its own copy at its own threshold, and by then the account is in whatever state that rule says. Anything that acts earlier has to do three unglamorous things: measure the same figure the rule measures, act on it without being talked out of it by a bad afternoon, and not get looser as the day goes on. Those are mechanics, and they are specific.

What your prop firm is measuring

Three numbers recur, and all three are measured against you.

Daily loss. The day's profit and loss against a floor. Whether it counts open positions or only closed ones is a rule detail, and it changes when the floor is reached.

Trailing drawdown. Equity measured against a high-water mark rather than against a starting balance. The mark moves up as the account grows and does not move back down inside the rule's window, so the floor follows the account's best point rather than its opening one. Some rule sets take that mark from intraday equity, others from the end-of-day balance, and the two produce different floors from identical trading.

Contract caps. A ceiling on position size, usually stated per instrument.

The firm's copy of these numbers decides the account's status. Any other copy is a guard, not a verdict.

What a limit has to do to help

Measure the whole day, not the closed part. Realized and unrealized added together is the figure a guard checks its floor against, so a position still open counts while it is still open.

Watch a number its user chose. A guard enforces the limits configured into it, which is what allows its floor to sit somewhere other than the threshold at the far end of the connection.

Flatten first, then block. Reaching a floor is not the same as being out of the position. The order that matters is: submit closing orders, cancel the resting ones — the exposure-increasing ones while the position is still open, all of them once flat — and only then treat the day as finished.

Confirm before it latches. One bad snapshot from a feed should not end a session, so an equity breach worth locking on is one seen twice in a row. Position counts need no price to be correct, so an over-cap position can be acted on immediately.

Trim on size, rather than flatten. A position over its cap is over by a number of contracts, not in its entirety; reducing it to the cap leaves the compliant remainder alone.

Reset on the trading day. The futures trading day turns over at 5:00 PM CT, and a guard resetting anywhere else is measuring a different day from the session it is watching. The lock also has to survive a platform restart, or restarting the platform is the override.

Carry the high-water mark the way the rule carries it. Two modes are needed because rule sets anchor the mark differently: one re-anchors it to the day's opening equity, the other carries the balance forward across sessions.

Give ground slowly. Tightening a limit can apply immediately. Loosening one cannot, or the limit is worth only as much as the worst hour of the day; deferring a loosened setting to the next rollover is what makes the number binding.

Say something before the floor. A guard that speaks only at 100% gives no warning at all. A proximity reading — moving an account from armed to warned at a set fraction of the way to a floor — is a state the guard can show before the floor itself is reached.

Where a limit can live

Three places, and they are three different things.

At the firm or the broker. This is the rule the account is graded on. It is the copy that settles the account's status, and its threshold is the one in the account agreement rather than one you pick.

In the platform's or the broker account's own settings. What is on offer here varies by broker, by account type and by connection type, so the only reliable answer is whatever your own account actually exposes. That is worth establishing rather than assuming, in either direction.

Inside the platform, as an add-on watching the account. Something running at the account level works from the balance, P&L and position updates it is handed, computes its own figures, and acts on thresholds you set. It runs only while the platform does, which is the boundary worth knowing: it sits on your side of the connection, alongside the rule at the other end rather than in place of it.

Where this shows up in my own tools

HardDeck is the add-on I built for this and run on my own funded account every session. It is a NinjaTrader 8 Add-On rather than an indicator, so it runs at the account level with nothing on a chart, and it starts disarmed. Once an account is armed it evaluates a daily loss limit, a profit fence, a trailing drawdown in either high-water-mark mode, and per-instrument contract caps on every update, and the account card turns from ARMED to WARN once you are 80% of the way to any of the first three. On a breach it submits closing orders, cancels resting ones and locks the day; the lock survives a NinjaTrader restart and clears at the 5:00 PM CT rollover. The lockout hands you the day's numbers — trades, wins, losses, largest losing trade, peak versus final P&L — plus notes raised only when the fills show it.

Built custom. I do this for hire — fixed quote, most jobs under a week. Get a quote →