Skip to main content
risk managementposition sizingstop loss
Risk management for automated trading

Risk management for automated trading

Profitable bot strategies are common. Profitable bot strategies that survive long enough to compound those gains are rare. The difference is risk management — the unglamorous mathematics that determines whether a string of losses destroys your account or merely dents it.

Most bot operators obsess over entry signals and take-profit percentages while ignoring position sizing, drawdown limits, and correlation risk. This is like building a race car and forgetting the brakes. This guide covers the quantitative frameworks that professional traders use to protect capital, survive inevitable losing streaks, and keep bots running through market regimes that would wipe out unprotected accounts.

Key Takeaways

  • The 1-2% rule: never risk more than 1-2% of total capital on any single deal. On a $5,000 account, that's $50-$100 maximum loss per deal.
  • Kelly Criterion calculates optimal position size based on win rate and reward-to-risk ratio. Half-Kelly (50% of the formula result) is safer for volatile crypto markets.
  • Stop loss strategies vary: fixed percentage (simple), ATR-based (adapts to volatility), trailing (locks in profits), and break-even (eliminates risk after initial gain).
  • Correlation risk is the hidden killer: 5 bots on BTC, ETH, SOL, AVAX, and LINK ≈ 3 independent bets, not 5. A market-wide drop hits all simultaneously.
  • Risk of ruin at 2% per deal: even 10 consecutive losses produces only 18.3% drawdown — painful but survivable. At 10% per deal, 10 losses = 65.1% drawdown — account-destroying.
  • Portfolio heat (total open risk across all bots) should never exceed 6% of account value at any given time.

Trading risk

The dollar amounts and percentages in this guide are worked examples, not recommendations. Crypto trading can lose money — size every bot with funds you can afford to lose, and read the full Risk Disclosure before going live.

Position Sizing Methods

Position sizing answers the most important question in trading: how much of your capital to risk on each deal. Get this wrong, and even a winning strategy will eventually blow up your account through variance alone.

Method 1: Fixed Amount Per Deal

The simplest approach — allocate a fixed dollar amount to each bot deal regardless of account size.

Example: Allocate $100 per deal, regardless of whether your account is $1,000 or $10,000.

Pros: Simple, easy to track, consistent execution. Cons: Doesn't scale. $100 is 10% risk on a $1,000 account (too much) but only 1% on a $10,000 account (conservative). As your account grows, you're under-risking. As it shrinks, you're over-risking.

When to use: Only during initial testing with small amounts. Graduate to percentage-based sizing as soon as your strategy proves profitable.

Method 2: Percentage-Based (The 1-2% Rule)

Risk a fixed percentage of your current account balance on each deal. This scales naturally — you risk more when you're winning (larger account) and less when you're losing (smaller account).

The Rule: Never risk more than 1-2% of total capital on a single deal.

Calculation:

Maximum Loss Per Deal = Account Balance × Risk Percentage

$5,000 account × 2% risk = $100 maximum loss per deal
$5,000 account × 1% risk = $50 maximum loss per deal

How to apply to DCA bots:

Your "risk per deal" is the maximum you'd lose if the deal hits your stop loss (or your worst-case scenario if running without a stop loss):

Position Size = Maximum Loss ÷ Stop Loss Distance (%)

If max loss = $100 and stop loss = 10%:
Position Size = $100 ÷ 0.10 = $1,000 total deal size

This means your DCA bot's maximum capital per deal (base order + all safety orders) should not exceed $1,000.

The 1-2% rule doesn't mean you only invest 1-2% of your capital. It means your maximum loss on any single deal is 1-2%. If your stop loss is at 10%, you can invest up to 10-20% of your capital in that deal — because a 10% loss on 20% of capital = 2% account loss.

Method 3: Kelly Criterion

The Kelly Criterion is a formula from information theory that calculates the mathematically optimal percentage of capital to risk based on your edge — how often you win and how much you win relative to losses.

Formula:

Kelly % = W - [(1 - W) / R]

Where:
W = Win rate (as decimal, e.g., 0.70 for 70%)
R = Win/Loss ratio (average win ÷ average loss)

Example: Your DCA bot has a 75% win rate with average wins of $45 and average losses of $80:

W = 0.75
R = $45 / $80 = 0.5625

Kelly % = 0.75 - [(1 - 0.75) / 0.5625]
Kelly % = 0.75 - [0.25 / 0.5625]
Kelly % = 0.75 - 0.4444
Kelly % = 0.3056 → 30.56% of capital per deal

The problem: Full Kelly is extremely aggressive. A single string of losses can produce devastating drawdowns. In practice, professional traders use Half-Kelly (50% of the result) or Quarter-Kelly (25%).

Full Kelly: 30.56%  → Too aggressive for crypto
Half Kelly: 15.28%  → Moderate — suitable for proven strategies
Quarter Kelly: 7.64% → Conservative — recommended starting point

Kelly Criterion requires accurate win rate and win/loss ratio estimates. If your backtest shows 80% win rate but real trading delivers 65%, your Kelly calculation is dangerously wrong. Always use conservative estimates and at minimum half-Kelly in live trading. For backtesting methodology, see our Backtesting Guide.

MethodFormulaProsConsBest For
Fixed Amount$X per deal (constant)Simple, predictableDoesn't scale with account growth/declineTesting phase only
Percentage (1-2%)Account × 1-2%Scales naturally, limits max lossRequires stop loss to calculate correctlyAll bot traders — recommended default
Kelly CriterionW - [(1-W)/R]Mathematically optimal growthRequires accurate stats, very aggressive at full KellyExperienced traders with 100+ trade history
Half-KellyKelly ÷ 2Balance between growth and safetyStill requires accurate statisticsProven strategies with stable metrics

Stop Loss Strategies

A stop loss is the maximum pain you're willing to accept on a single deal. Without one, a DCA bot buying into a 60% decline will consume all its capital and leave you holding a massive unrealized loss. There are four main approaches.

Fixed Percentage Stop Loss

Set a fixed percentage below your entry (or VWAP for DCA bots) at which the bot closes the deal at a loss.

Common levels:

  • Conservative: 5-10% (exits quickly, preserves capital, but triggers frequently)
  • Moderate: 10-20% (allows room for DCA averaging to work)
  • Wide: 20-40% (for DCA bots with many safety orders — only exits on major breakdowns)

Calculation example on $5,000 account with 2% risk rule:

Max loss per deal = $5,000 × 2% = $100

If stop loss = 15%:
Maximum position size = $100 ÷ 0.15 = $666.67

If stop loss = 25%:
Maximum position size = $100 ÷ 0.25 = $400

Wider stop losses require smaller position sizes to maintain the same dollar risk.

ATR-Based Stop Loss (2× ATR)

Instead of an arbitrary percentage, set the stop loss at 2× the Average True Range — this adapts to the asset's actual volatility.

Formula:

Stop Loss Price = Entry Price - (2 × ATR_14)
Stop Loss % = (2 × ATR_14) ÷ Entry Price × 100

Example with BTC at $100,000:

If 14-day ATR = $3,200:

Stop Loss Price = $100,000 - (2 × $3,200) = $93,600
Stop Loss % = ($6,400 ÷ $100,000) × 100 = 6.4%

If 14-day ATR = $5,500 (high volatility period):

Stop Loss Price = $100,000 - (2 × $5,500) = $89,000
Stop Loss % = ($11,000 ÷ $100,000) × 100 = 11.0%

The stop automatically widens during volatile periods (preventing premature exits) and tightens during calm periods (protecting capital).

Trailing Stop Loss

A trailing stop follows price upward, locking in profits as the position moves in your favor. It only moves up — never down.

How it works:

  1. Initial stop: set at -5% from entry
  2. Price moves up 8%: stop moves to +3% (8% - 5%)
  3. Price moves up 12%: stop moves to +7% (12% - 5%)
  4. Price reverses, drops 5% from peak: stop triggers at +7%, locking in profit

Best for: Trending markets where you want to capture extended moves without manually monitoring. Less effective in choppy markets where temporary pullbacks trigger the stop prematurely.

Break-Even Stop Loss

After a position reaches a specified profit threshold, the stop loss automatically moves to the entry price (break-even). This guarantees you won't lose money on the deal.

Configuration:

Activation: When position is +2% above VWAP
Action: Move stop loss to VWAP (entry price)
Result: Worst case = breakeven, best case = full take profit or trailing profit

The most powerful configuration combines break-even with trailing: once the position hits +2%, the stop moves to break-even. Then a trailing stop activates, ratcheting the stop higher as price rises. This creates a one-way safety net that can only improve your exit price, never worsen it.


Maximum Drawdown Limits

Drawdown limits are circuit breakers for your bots. They define the maximum cumulative loss you'll tolerate before pausing trading to reassess.

TimeframeMaximum DrawdownAction When Hit
Daily10% of accountPause all bots for 24 hours. Review what happened.
Weekly20% of accountPause all bots. Reduce position sizes by 50% when resuming.
Monthly30% of accountFull stop. Re-evaluate all strategies. Only resume with proven backtested configs.

Why These Numbers?

A 10% daily drawdown means something exceptional happened — either a black swan event, a misconfigured bot, or a market regime change your strategy wasn't designed for. Continuing to trade after a 10% day usually makes things worse.

A 30% monthly drawdown is the mathematical boundary between "recoverable" and "dangerous." Recovering from 30% requires a 42.9% gain. Recovering from 50% requires a 100% gain. The deeper you go, the exponentially harder recovery becomes.

DrawdownRecovery RequiredTime to Recover (at 5%/month)
10%11.1%~2.2 months
20%25.0%~5 months
30%42.9%~8.6 months
40%66.7%~13.3 months
50%100.0%~20 months

Drawdown limits must be enforced automatically, not manually. If you're relying on self-discipline to pause bots after a 10% daily loss, you'll rationalize continuing ("it'll bounce back") exactly when you should be stopping. Configure your platform's auto-pause features or set alerts that trigger before you reach the limit.


Correlation Risk: The Hidden Killer

This is the most underestimated risk in automated trading. Running five bots sounds like diversification — five independent strategies, five chances to profit. But if all five trade crypto assets that move together, you have one big bet wearing five disguises.

Understanding Correlation

Correlation measures how closely two assets move together, on a scale from -1 to +1:

CorrelationMeaningExample
+1.0Move in perfect lockstepBTC and BTC futures
+0.7 to +0.9Strongly correlatedBTC and ETH (typically 0.75-0.85)
+0.4 to +0.6Moderately correlatedBTC and SOL (typically 0.55-0.70)
0No relationshipBTC and Gold (varies)
-0.5 to -1.0Inversely correlatedBTC and USD index (sometimes)

The Problem: 5 Bots ≠ 5 Independent Bets

Scenario: You run 5 DCA bots with $1,000 each on:

  1. BTC/USDT
  2. ETH/USDT
  3. SOL/USDT
  4. AVAX/USDT
  5. LINK/USDT

You think you have 5 independent positions. In reality:

  • BTC and ETH correlation: ~0.80
  • BTC and SOL correlation: ~0.65
  • BTC and AVAX correlation: ~0.60
  • BTC and LINK correlation: ~0.55

During a market-wide crash (like a regulatory announcement or exchange failure), ALL five drop simultaneously. Your "diversified" $5,000 portfolio behaves like a single $5,000 BTC position because correlations spike to 0.90+ during crashes.

Effective independent positions: ~3 (not 5)

How to Manage Correlation Risk

  1. Accept it: In crypto, most assets are positively correlated to BTC. True diversification within crypto is limited.
  2. Size accordingly: If your 5 bots are effectively 3 independent bets, your total position should be sized for 3 bets, not 5. Reduce each by ~40%.
  3. Monitor correlation spikes: During high-fear periods (BTC down >5% in a day), correlations increase. Consider pausing lower-conviction bots during market stress.
  4. Add truly uncorrelated exposure: Stablecoin farming, options strategies, or non-crypto assets for genuine diversification.

Capital Allocation: The Core-Satellite Approach

Professional portfolio managers divide capital into risk tiers. Apply the same principle to bot trading.

The 60/30/10 Framework

Core (60% of capital): Major pairs — BTC/USDT, ETH/USDT
  → Conservative bot settings
  → These pairs recover from drawdowns historically
  → Lower returns but highest survival probability

Satellite (30% of capital): Mid-cap pairs — SOL/USDT, AVAX/USDT, MATIC/USDT
  → Moderate bot settings
  → Higher volatility = more trading opportunities
  → Accept higher individual drawdown risk

Speculative (10% of capital): Small/micro-cap — DOGE, PEPE, or new-listing bots
  → Aggressive settings
  → Capital you can afford to lose entirely
  → Potential for outsized returns (or total wipeout)

Example with $5,000 total capital:

TierAllocationPairsBotsRisk Per Deal
Core (60%)$3,000BTC, ETH2 bots, $1,500 each1% ($15/deal)
Satellite (30%)$1,500SOL, AVAX2 bots, $750 each2% ($15/deal)
Speculative (10%)$500DOGE1 bot, $5003% ($15/deal)

Notice: even though the risk percentage is higher for speculative bots, the actual dollar risk per deal ($15) stays constant across all tiers. This is intentional — it prevents speculative bets from disproportionately impacting your overall account.

The core-satellite approach forces discipline. When a speculative bot blows up (it will, eventually), you lose at most 10% of total capital — annoying but not devastating. Your core 60% continues compounding through the setback, and recovery is straightforward.


Risk-Reward Ratio

The risk-reward ratio compares your potential loss to your potential gain on each deal.

Minimum Standards

Risk:RewardMeaningBreakeven Win Rate
1:1Risk $1 to make $150% (coin flip)
1:2Risk $1 to make $233.3%
1:3Risk $1 to make $325%
1:4Risk $1 to make $420%

Why 1:2 minimum matters:

At 1:2 risk-reward, you only need to win 33.3% of your trades to break even. Most DCA bots achieve 70-85% win rates. This means even with significant deterioration in strategy performance, you're still profitable.

At 1:1, you need a 50% win rate to break even — a strategy with a 70% win rate has only a 20% buffer before it becomes unprofitable. At 1:2, that buffer is 37% — much more resilient.

Win Rate × Risk:Reward Breakeven Table

Win Rate1:1 R:R1:2 R:R1:3 R:R
40%-20%+20%+60%
50%0% (breakeven)+50%+100%
60%+20%+80%+140%
70%+40%+110%+180%
80%+60%+140%+220%

Values show expected return per 100 deals, expressed as % of risk amount.

A 70% win rate with 1:2 risk:reward means for every 100 deals risking $100 each: 70 wins × $200 = $14,000 gains, 30 losses × $100 = $3,000 losses. Net: +$11,000 (110% return on risk).


Real Example: $5,000 Portfolio with 3 Bots

Let's build a complete risk management framework for a real portfolio.

Setup

ParameterValue
Total Capital$5,000
Number of Bots3
Max Risk Per Deal2% = $100
Max Daily Drawdown10% = $500
Max Portfolio Heat6% = $300

Bot Configuration

BotPairCapitalStop LossMax Loss/DealMax Position Size
Bot 1BTC/USDT$2,00015%$100$666
Bot 2ETH/USDT$1,50012%$100$833
Bot 3SOL/USDT$1,50020%$100$500

Worst-Case Analysis

Scenario: All 3 bots hit stop loss simultaneously

Bot 1 loss: $100 (2% of account)
Bot 2 loss: $100 (2% of account)
Bot 3 loss: $100 (2% of account)
Total loss: $300 (6% of account)

Account after: $5,000 - $300 = $4,700

A 6% drawdown from simultaneous stop losses across all bots. Painful, but far from catastrophic. Your daily drawdown limit (10%) hasn't even been breached — you can continue trading with adjusted sizes.

Recovery Math

At 2% risk per deal and 70% win rate with 1:2 risk-reward:

Per deal expected value = (0.70 × $200) - (0.30 × $100) = $140 - $30 = $110
Average profit per deal: $110 × risk fraction = varies, but approximately $20-$40 net per completed deal cycle

Recovery from $300 loss ≈ 8-15 completed deals ≈ 3-7 days of active trading

The key insight: because position sizing limits losses to 2%, even the worst-case scenario (all bots failing simultaneously) is recoverable within a week or two.


Risk of Ruin Calculation

Risk of ruin measures the probability that a string of consecutive losses will destroy your account beyond recovery.

The Math at Different Risk Levels

Consecutive losses and their cumulative impact (compounded):

Consecutive LossesAt 2% Risk/DealAt 5% Risk/DealAt 10% Risk/Deal
3 losses-5.88%-14.26%-27.10%
5 losses-9.61%-22.62%-40.95%
7 losses-13.18%-30.17%-52.17%
10 losses-18.29%-40.13%-65.13%
15 losses-26.14%-53.67%-79.41%
20 losses-33.24%-64.15%-87.84%

At 2% risk: 10 consecutive losses (extremely unlikely with a 70% win rate) produces only an 18.3% drawdown. This is survivable. Your account drops from $5,000 to $4,085 — you reduce position sizes slightly and continue.

At 10% risk: 10 consecutive losses produces a 65.1% drawdown. Your account drops from $5,000 to $1,744. You now need a 187% gain to recover. The strategy is effectively dead.

Probability of Consecutive Losses

With a 70% win rate, the probability of consecutive losses:

Consecutive LossesProbability
3 in a row2.70%
5 in a row0.243%
7 in a row0.022%
10 in a row0.00059%

A 70% win rate bot has a 2.7% chance of 3 consecutive losses (happens roughly once every 37 deals) and a 0.024% chance of 7 consecutive losses (roughly once every 4,100 deals). At 2% risk, even the rare 7-loss streak only costs 13.2% — manageable.

This is why the 2% rule is universal among professional traders. It's not about maximizing returns on each deal — it's about mathematical survival. At 2% risk, even extremely unlikely loss sequences can't destroy your account. At 10% risk, a moderately unlikely sequence ends your trading career.


Portfolio Heat: Total Open Risk

Portfolio heat measures your total exposed risk across all active bot positions at any given moment.

The 6% Rule

Total open risk across all bots should never exceed 6% of account value.

Calculation:

Portfolio Heat = Sum of (Position Size × Stop Loss %) for each active deal

Bot 1: $600 position × 15% SL = $90 risk
Bot 2: $700 position × 12% SL = $84 risk
Bot 3: $450 position × 20% SL = $90 risk

Total Portfolio Heat = $90 + $84 + $90 = $264
Portfolio Heat % = $264 / $5,000 = 5.28% ✓ Under 6% limit

If Bot 1 fills additional safety orders, increasing its position to $1,200:

Bot 1: $1,200 position × 15% SL = $180 risk
Bot 2: $700 position × 12% SL = $84 risk
Bot 3: $450 position × 20% SL = $90 risk

Total Portfolio Heat = $180 + $84 + $90 = $354
Portfolio Heat % = $354 / $5,000 = 7.08% ✗ EXCEEDS 6% limit

Action: Reduce Bot 3's position or pause new entries until heat drops below 6%.

Why 6%?

At 6% portfolio heat, the absolute worst case (all positions hit stop loss simultaneously) costs you 6% of your account. Combined with the knowledge that this is extremely unlikely (requires ALL bots to fail at the same time), 6% provides ample room for normal operation while preventing catastrophic scenarios.

Portfolio heat is the risk metric most bot operators completely ignore. They calculate risk per deal correctly but never add up the total risk across all active deals. During market-wide drawdowns, correlations spike and ALL bots tend to be losing simultaneously — portfolio heat becomes the actual risk, not individual deal risk.


Risk Management Checklist

Before running any automated trading strategy, verify each item:

#CheckStatus
1Risk per deal ≤ 2% of accountRequired
2Stop loss configured on every botRequired
3Total capital per bot calculated (including all safety orders)Required
4Portfolio heat ≤ 6% of accountRequired
5Daily drawdown limit set (10%)Required
6Weekly drawdown limit set (20%)Recommended
7Monthly drawdown limit set (30%)Recommended
8Correlation between pairs assessedRecommended
9Core-satellite allocation definedRecommended
10Strategy backtested across bull, bear, sidewaysRequired

For comprehensive security practices when running bots, see our Security Best Practices guide.


Frequently Asked Questions

Is 2% risk per deal too conservative for small accounts?

No. The 2% rule is more important for small accounts, not less. A $500 account with 10% risk per deal ($50) can be wiped out by 7 consecutive losses — something that happens with any strategy eventually. At 2% risk ($10 per deal), those same 7 losses cost only $67 (13.4%). The account survives and can recover. Aggressive position sizing on small accounts is the fastest path to zero.

Should I use stop losses with DCA bots?

For altcoins — always. An altcoin can drop 90% and never recover. A stop loss at 25-40% limits catastrophic losses. For BTC and ETH DCA bots, many experienced traders run without stop losses because these assets have historically always recovered. However, this ties up capital for extended periods during deep drawdowns. The decision depends on your time horizon and capital availability. For more on DCA configuration, see our DCA Bot Strategy Guide.

How do I calculate correlation between my trading pairs?

Most advanced trading platforms display correlation matrices. As a rough guide: BTC/ETH ≈ 0.80, BTC/SOL ≈ 0.65, BTC/DOGE ≈ 0.50. During crashes, all correlations converge toward 1.0. For practical purposes, treat any two top-50 crypto assets as having at least 0.50 correlation — your five-bot portfolio provides the diversification of approximately three independent positions.

What's the maximum number of bots I should run simultaneously?

This depends on capital. The formula: Total Capital ÷ (Average Deal Size × Number of Safety Orders) = Maximum Bots. For a $5,000 account with $500 average maximum deal size: $5,000 ÷ $500 = 10 bots maximum. But factor in portfolio heat (6% limit) and correlation — practically, 3-5 bots is optimal for most $5,000 accounts.

How do I handle a bot that keeps hitting its stop loss?

Three consecutive stop losses on the same bot = pause and review. The strategy may be misconfigured for current market conditions. Check: is the stop loss too tight for the pair's volatility (use ATR-based stop)? Has the market regime changed (use Supertrend or ADX to confirm)? Is the entry timing wrong (review indicator signals)? Never increase position size to "win back" losses — that's the textbook path to ruin. For indicator optimization, see our Technical Indicators Guide.

Is the Kelly Criterion practical for crypto bot trading?

Full Kelly is too aggressive for crypto's extreme volatility. Half-Kelly or quarter-Kelly is practical after you have at least 100 completed deals to calculate reliable win rate and risk-reward statistics. Before that, stick with the 1-2% rule — it's a universal safety net that works regardless of strategy specifics.


Create an account

Put your knowledge into practice by opening a Freya account today.

Register Now
This content is for educational purposes only and does not constitute financial advice. Cryptocurrency trading involves significant risks. Never invest more than you can afford to lose.