# Reinvest Profit

> How profit reinvestment works in Veles bots.

**Reinvest Profit** is a setting that automatically adds a portion of the NET profit from a closed winning trade back into the bot's deposit, increasing the size of subsequent positions.

## How It Works

After each trade that closes in profit, the bot:
1. Calculates the NET profit from the trade.
2. Takes the configured percentage of that amount.
3. Adds the result to the bot deposit.

> **Reinvest amount = NET profit × reinvestment percentage**

Works in live bots and backtests.

:::note[Note]
The reinvested amount is not shown in statistics — the change is only visible through the updated deposit in the bot card. NET profit is calculated excluding funding fees.
:::

## Limitations

| Parameter | Spot | Futures |
|---|---|---|
| Reinvestment percentage | Any value | Maximum 50% |

- If a trade closes at a loss, reinvestment is **not applied**.
- The calculation is based on NET profit — after the exchange trading fees are deducted.
- On the Spot, reinvestment can only work if the deposit currency and profit currency match. Otherwise, the bot has nothing to reinvest. Check how the ["Profit Currency"](https://help.veles.finance/en/platform/settings/take-profit/) parameter works in your strategy.

:::note
It is recommended that the reinvestment percentage does not exceed the value \
"100/bot leverage".

For example, for a bot with 5x leverage, the maximum reinvestment is \
100/5 = 20%.
:::

## Examples

**Example 1: winning trade**
- Bot deposit = 1000 USDT
- Reinvestment = 20%
- NET profit = 50 USDT

Reinvest amount: 50 × 20% = **10 USDT** → new deposit: **1010 USDT**.

---

**Example 2: losing trade**
- Loss = −30 USDT

Reinvestment is **not triggered**. The deposit stays unchanged.

## Effect on Strategy

Each winning trade grows the deposit — future positions open with a larger volume, which increases absolute returns over time.

The flip side: the bot also takes **larger losses** on losing trades, since it operates with a growing deposit.

:::caution[Important]
**Do not use Reinvest Profit together with Stop-Loss** without manual oversight. When a stop-loss triggers, the bot deposit stays inflated even though your actual capital has decreased. Activate the "Stop bot after Stop-Loss execution" option in the bot; once the bot has stopped, manually adjust its deposit to a safe level, and only then restart the bot.
:::

## Summary

Use Reinvest Profit when:
- your strategy consistently closes trades in profit;
- you're ready to periodically review and manually adjust the deposit;
- stop-loss is either disabled or you actively monitor the deposit after each stop triggers.

Always evaluate the impact and a Maximum drawdown (MAE) through a [**backtest**](https://help.veles.finance/en/platform/components/backtests/) before running in a live bot.
