defi stop losses

This article aims to provide insight into how users can manage price risk in decentralized finance (DeFi) by setting stop losses. If you are unfamiliar with DeFi risk, do read our introductory articles on DeFi risks, DeFi price risk, and the framework to manage DeFi risks before reading this article.

What Is a Stop Loss?

A stop loss is a pre-placed order to buy or sell a specific security when it hits a certain price in order to limit a loss. In trading, stop losses are essential for managing the risks of one’s positions. Traders place stop losses to limit potential losses, in line with their preferred risk-to-reward ratio for their trades. Risk-to-reward ratio refers to the relationship between the amount of loss traders are willing to take and the amount of potential gain they could make. Stop losses are highly advantageous in volatile markets as they prevent traders from suffering huge losses due to unexpected swings and movement.

The Prospect Theory

Prospect Theory, also known as the Loss Aversion Theory, is a popular behavioral economics concept that illustrates how investors value gains and losses differently. It suggests that individuals are more inclined to make decisions based on perceived gains rather than perceived losses. 

In financial markets, traders who do not adopt a systematic risk management approach of setting stop losses are more susceptible to larger drawdowns, risking a larger percentage of their portfolio than intended. Many traders avoid setting stop losses due to the undesirable idea of realizing their losses. Instead, they tend to hold on to their positions in hopes that prices will eventually bounce back up, overlooking the further losses they could continue to incur.

A Trader’s Mindset

The way to assess a trader’s performance is not by looking at one trade but at the cumulation of numerous trades that have resulted in a profitable portfolio. The key to achieving this is risk management. Many professional traders find good trading opportunities by measuring the possible reward for the amount of risk they are willing to take. This is done by establishing a profit level that they believe is achievable and the maximum drawdown they are willing to risk. 

For example, Trader A buys a stock at $50 with a preferred risk-to-reward ratio of 1:2. This means that if his take profit level is at $60 ($10 profit), he is willing to risk the price falling to $45 ($5 loss) before cutting losses. By constantly trading with this risk-to-reward ratio, Trader A would have an excess profit of $25 with 10 winning trades (+$100) and 15 losing trades (-$75). This also means that he turned a profit despite having a win rate of less than 50%, simply by managing risk to reward. 

On the other hand, Trader B, who set a lower stop loss at a risk-to-reward ratio of 1:1 would have experienced a loss of $50. Trader C, who did not set a stop loss, could have experienced a much greater loss over the same 35 trades. Without proper risk management, we cannot calculate potential losses, which is highly dangerous for trading.

Types of Stop Losses

There are various types of stop losses available for traders to use according to their risk tolerance and needs. 

1. Buy/Sell Stop

A buy/sell stop is the simplest type of stop loss used by traders to limit their downside. A buy stop closes a short position and is triggered when the price rises above the specified level, while a sell stop closes a long position and is triggered when the price falls below the specified level. Buy/sell stops are straightforward and help traders set the maximum drawdown they are willing to risk.

2. Stop-Limit

A stop-limit order is a combination of a stop order and a limit order, and thus, involves the setting of a stop price and a limit price. 

Stop Order: A stop order is an order that becomes executable once the target price is reached. It is filled in its entirety at the current market price, regardless of any changes in the current market price.

Limit Order: A limit order is only executable at the target price or a more favorable price than the target price.

Stop-Limit Order: Combining a stop order with the features of a limit order ensures that the order will not get filled once the pricing becomes unfavorable based on the investor’s limit within a specified timeframe. Thus, in a stop-limit order, after the stop price is triggered, the limit order takes effect to ensure that the order is not completed unless the price is at or better than the limit price specified by the investor. Stop-limit orders give traders precise control over when the order should be filled and are often used to lock in profits or limit downside losses.

For example, Trader A buys an asset at $20 and sets a sell stop-limit. He sets a stop price of $15 and a limit price of $10. When the price falls to $15, a sell limit order is automatically placed at $10.  When the asset’s price drops to $10, the limit order is triggered and will be filled at any price above $10. However, if the price falls too quickly below $10 before the order is filled, the position will not be closed.

This is so traders do not get stopped by sudden spikes in prices where the price suddenly falls significantly but recovers almost immediately. However, such a stop loss is dangerous as there is a possibility that the price may never return to that level. With proper backtesting and building of a strategy, traders can use this to their advantage to trade highly volatile assets.

3. Trailing Stop Loss

A trailing stop loss is a dynamic stop order that allows traders to set a maximum amount of loss instead of a fixed price level, either in terms of percentage or a fixed dollar amount. This means that the stop price moves along with the asset’s price. Trailing stop losses are great for those who trade trends or breakouts and wish to close their position when price retraces after a huge run-up. 

For example, Trader A buys an asset at $100 and sets a trailing stop loss of 10% below the buy price of $90. If the price falls over 10%, the position will be closed. If the price remains above $90 and below $100, the stop loss stays in place. If the price increases to $150, the stop loss trails accordingly, such that it will be $135, 10% below $150.

This stop loss type is useful for traders without a definite take-profit level due to the nature of a volatile asset. Instead of having a stop loss below the entry price, the trailing stop loss automatically moves with the asset price, allowing traders to close out at a profit closer to breakeven if the price falls. However, such a trailing stop loss can stop a trader out early if the price action moves beyond their trailing stop before increasing or decreasing significantly. 

How to Use Stop Loss in DeFi

As a form of stop loss, DeFi users on decentralized platforms such as 1inch can set a limit price to swap tokens to stablecoins. For example, if a user is holding Ether (ETH) and intends to sell the token if it hits a certain price, he can set a limit order at a specified price. The platform will automatically swap the tokens into stablecoins at the limit price.


Investors can use many types of stop losses to manage their risk when trading. These should be chosen based on risk tolerance and the strategy used. Investors should also implement a stop loss to help cultivate better trading habits and to prevent their emotions from taking over. It is important to understand that trading is a long-term game, and it requires one to have a strong foundation in managing risk.

At Treehouse, we want to empower people to navigate DeFi confidently, and this includes helping users with understanding and assessing risk properly. In case you missed it, check out our recommended list of risk-related pieces! 

  1. How to Make Sense of Metrics in DeFi
  2. The Truth About Audits in DeFi
  3. DeFi Risks: What You Need to Know
  4. How to Manage Your DeFi Risks With This Framework
  5. Introducing Price Risk and Basic Trading Strategies
  6. Flash Loans and Flash Loan Attacks? What Are They and How to Prevent Them?
  7. A Look Back at Past Crypto Winters: Then Till Now
  8. How to Measure Your Price Risk in DeFi
  9. Diversify Your Portfolio to Manage Your DeFi Price Risk

New to DeFi? If you found this useful, check out our other Learn DeFi articles to dive deeper into the wonderful world of DeFi! Alternatively, browse our Insights section to read more in-depth analyses on the DeFi space. You can also try out our flagship product, Harvest, to get a comprehensive analysis of your DeFi assets. Lastly, subscribe to newsletter updates in the box below!


This publication is provided for informational and entertainment purposes only. Nothing contained in this publication constitutes financial advice, trading advice, or any other advice, nor does it constitute an offer to buy or sell securities or any other assets or participate in any particular trading strategy. This publication does not take into account your personal investment objectives, financial situation, or needs. Treehouse does not warrant that the information provided in this publication is up to date or accurate.