Hull Moving Average (HMA) strategies are algorithmic trading methods that use this type of moving average to identify market trends, entry and exit signals, and potential trend reversals. The main goal of these strategies is to capture the fastest and smoothest market movements while minimizing the lag typical of traditional moving averages.
Unlike classic moving averages, HMAs respond more quickly to price changes, making the strategy particularly suitable for volatile markets or markets with strong, established trends. HMA-based strategies can be applied to a variety of assets, from major stock markets to cryptocurrencies, and across different timeframes, depending on the desired trading style (intraday, swing, or multi-day).
The Hull Moving Average (HMA) is a moving average developed by Alan Hull to reduce the lag typical of traditional moving averages while maintaining a smoother line compared to a simple moving average. The HMA combines weighted moving averages (WMA) and the square root of the period to achieve higher responsiveness, allowing traders to follow trends more quickly and accurately.
The general formula for the HMA is:
Calculate a WMA using half of the chosen period.
Subtract the WMA over the full original period from the half-period WMA and multiply the result by 2.
Apply a final WMA over the square root of the chosen period.
The result is a smooth and responsive moving average, capable of highlighting trends in real time and reducing false signals caused by minor price fluctuations.
The strategy presented in this example was developed by the Opportrade team and tested on ETH/EUR using a 1-hour timeframe throughout 2025. The goal of the strategy is to capture significant bullish movements by following the trends highlighted by the Hull Moving Averages, filtering trades to execute only when the trend is confirmed.
You can download the strategy for free from our Marketplace and start testing and customizing it as you like!
The long entry signal is triggered when the faster Hull Moving Average (H_L1) crosses above the slower Hull Moving Average (H_L4). This crossover indicates a shift in bullish momentum: the more responsive HMA detects that the price is starting to move faster than the recent trend, signaling the potential start of a positive trend.
To increase the probability of success and reduce false signals caused by short-term fluctuations, the signal is filtered using a long-term SMA (SMA 500). The filter ensures that the order is executed only if the previous candle’s closing price is above the SMA(500), confirming that the market is in a well-established uptrend. In practice, this filter removes trades during sideways or bearish market conditions, allowing entries only when the likelihood of trend continuation is higher.
The signal is defined in Tradescript as follows:
SET H_L1 = REF( WMA( (WMA(CLOSE, 16) * 2) - WMA(CLOSE, 32), 6 ), 1 )
SET H_L4 = REF( WMA( (WMA(CLOSE, 16) * 2) - WMA(CLOSE, 32), 6 ), 4 )
SET C_L1 = REF(CLOSE, 1)
SET S_L1 = REF(SMA(CLOSE, 500), 1)
CROSSOVER(H_L1, H_L4) == TRUE AND
C_L1 > S_L1
This approach combines the speed and responsiveness of the Hull Moving Averages with the stability of the long-term trend, creating a long signal that enters the market only when bullish conditions are confirmed, thereby reducing exposure to false breakouts.
The long exit signal is triggered when the slower Hull Moving Average (H_L4_EXIT) crosses below the faster Hull Moving Average (H_L1_EXIT). This crossover indicates a potential weakening of bullish momentum and the beginning of a possible trend reversal. In other words, it signals that the price may stop rising rapidly and that the likelihood of the positive trend continuing is decreasing.
This signal helps protect accumulated gains and limit drawdown risk by closing the long position before a more significant reversal can erode capital. Unlike the entry signal, no additional trend filters are necessary here: the HMA crossover alone is sufficient to detect a meaningful change in momentum.
In Tradescript, the exit signal is defined as follows:
SET H_L1_EXIT = REF( WMA( (WMA(CLOSE, 16) * 2) - WMA(CLOSE, 32), 6 ), 1 )
SET H_L4_EXIT = REF( WMA( (WMA(CLOSE, 16) * 2) - WMA(CLOSE, 32), 6 ), 4 )
CROSSOVER(H_L4_EXIT, H_L1_EXIT) == TRUE
This approach ensures that the strategy automatically closes positions during periods of potential trend weakness, maximizing capital protection and allowing for a structured and timely exit, while minimizing the impact of false signals or short-term fluctuations.
The money management approach of this strategy depends heavily on the chosen asset, its price, and the initial capital allocated to the strategy. In this case, the strategy was tested and optimized on Ethereum/Euro (ETH/EUR) using 1-hour candles from 01/01/2025 to 19/09/2025, assuming an initial backtest capital of €10,000.
The entry signal generates a buy order of 4.2 ETH, while the exit signal generates a sell order of 4.2 ETH. Additionally, a long exposure limit of 4.2 ETH has been set, equal to the order size. This means the strategy is not allowed to open multiple positions simultaneously, and partial exits are not permitted: when the exit signal triggers, it closes the entire position.
To protect the position, each buy order is accompanied by a stop loss of the same quantity, set at a price 5% below the order placement price.
This Hull Moving Average-based strategy has been designed with a relatively conservative approach, prioritizing the quality of trades over quantity. Its goal is to capture the most significant bullish swings in the crypto markets while avoiding entries during sideways or bearish phases.
A key aspect of the strategy is to minimize the impact of the high fees typical of crypto markets by limiting the total number of orders without compromising the ability to capture fast and profitable movements. The signals are optimized to enter only in confirmed trends, reducing exposure to false breakouts and short-term fluctuations.
The strategy can be adapted to different timeframes: it is primarily designed for 30-minute to 2-hour candles, but the signal parameters can be adjusted to apply it on shorter or longer intervals depending on the desired trading style.
This strategy belongs to the broader class of moving average crossover strategies. To learn more about these strategies, we recommend reading the following article:
MOVING AVERAGES CROSSOVER STRATEGIESThis strategy is particularly suited for high-volatility crypto markets, such as Bitcoin and Ethereum, where rapid swings provide significant profit opportunities. It performs best in uptrending markets with decisive movements and tends to lose effectiveness during bearish or sideways phases.
Thanks to its design, the strategy is suitable both for traders who want to monitor multiple assets simultaneously and for those seeking an automated approach that minimizes time spent in front of charts while maximizing the capital’s performance during positive trends.
The strategy was tested on ETH/EUR using 1-hour candles from 01/01/2025 to 19/09/2025. The entry and exit signals, order sizing, and exposure limits were set as described in the previous sections. The initial capital for the backtest was €10,000, with fees set at 0.1% per order and no leverage applied (Margin Required 100%). The spread was neglected due to the high liquidity of Ethereum.
The strategy outperformed the market during the testing period, achieving a total return of 68.18% compared to a 14.47% buy & hold return. The drawdown remained relatively contained, with a maximum drawdown of 8.92%. Trading activity was active but controlled, averaging 16 orders per month. Fees impacted overall performance but did not compromise results, with a total of €1,351 in commissions.
Key metrics from the backtest:
Initial Capital: €10,000
Final Capital: €16,818
Total Return: 68.18%
Buy & Hold Return: 14.47%
Maximum Drawdown: 8.92%
Total Realized Profit (before fees): €8,170.22
Total Commissions: €1,351.73
Total Orders: 130 (entries + exits)
Winning Exits: 32
Losing Exits: 33
Win/Loss Ratio: 0.97
Sterling Ratio: 5.16
Calmar Ratio: 7.64
The Hull Moving Average-based strategy allows you to capture the fastest bullish moves in crypto markets, trading only in confirmed trends and minimizing the impact of false signals or sideways phases. Thanks to its conservative design and optimized parameters, it’s an excellent starting point for anyone looking to test and experiment with algorithmic trading strategies.
Want to try it right away? Download the strategy for free from the Opportrade Marketplace and test its potential on your favorite assets!