trend-followingmedium-high riskBacktest as of 2026-09-29

The trend bot people ask an AI to build, backtested on Hyperliquid

There is no AI inside this strategy. It is the kind of bot people ask an AI to build: hold a coin long while its trend is up and momentum agrees, sit in cash when it is not, and exit on a trailing stop. From 2024-08-15 to 2026-09-29 on Hyperliquid perps it returned +213.4% with a Sharpe of 1.15 and a 50.2% worst drawdown, net of fees, slippage and funding. That ranks 9th of the 18 strategies in our library by Sharpe.

By Keel Research Team · Data as of 2026-09-29 · how this backtest was produced
EquityDrawdown
Sharpe
1.15
default settings
Total return
+213.4%
Worst drawdown
−50.2%
Trades
1,141

2024-08-15 → 2026-09-29 · net of fees, slippage, and funding · price-only Sharpe 1.28 · these are the default settings, not a hand-picked best case.

At $1,000, this strategy’s worst historical dip was about $502. Free account, your own Hyperliquid keys. Keel only trades.

AI trading bots, and where this strategy fits

This page is about one trend strategy and how it tested. For what an AI trading bot can and can't do, and how to build one with an AI assistant and test it before it trades, read the AI trading bot guide.

How it works

How it works

This is the classic risk-managed trend bot, applied to the top-20 Hyperliquid perps. A coin qualifies as a long when its 10-day moving average is above its 30-day average, a two-week momentum reading agrees, and funding cost isn't extreme; otherwise its capital sits in cash. Qualifying coins are held equal-weight, and a position closes either when the trend flips or when price pulls back 2.5 ATRs from its high — a volatility-scaled trailing exit. The moving-average and momentum confirmations suppress false starts, while the trailing stop protects gains during big runs.

When it works best

Sustained directional moves across liquid majors — crypto's long, fat-tailed trends are exactly what this captures. When several majors trend together, the equal-weight book compounds hard and the trailing stop rides winners a long way.

When it struggles

Trend turns are the pain point: the exit lags by the cross-back, so every major reversal costs some give-back, and choppy ranges generate whipsaw entries that the confirmations reduce but don't eliminate. As a long-only book with no volatility target, it carries the full weight of crypto sell-offs — the maximum drawdown over the window was −50.2% — and it pays funding while crowded on the popular long side. This is a high-risk trend follower, honest about the drawdowns that come with it.

How it’s built

The exact strategy behind this backtest, with no black box. Fork it to change it and run your own backtest.

Configuration

Globalsconfig
target_timeframe1dbar_offset12h
UniverseassetsTop by Volume · HL Perps · 20 assets20 resolved
Executionorders
rebalanceOn Change

Factories

ema_crossfactory
Pipeline7 steps
PriceDataLoaderData Loader
ohlcv_1dstore
Parallel2 branches
entries
Parallel2 branches
const
ConstantForecastForecast Mapper
value1
gates
Parallel3 branches
trend_up
ema_crosscall
AboveThresholdFilterSignal Transform
threshold0
momentum_agrees
ROCIndicator
period14
AboveThresholdFilterSignal Transform
threshold0
funding_ok
FundingDataLoaderData Loader
use_cachetrue
BelowThresholdFilterSignal Transform
threshold0.0000625inclusivetrue
MaskAndSignal Composer
ApplyMaskSignal Composer
score_signalconstfilter_signalgates
bot_entrystore
exit_flip
ema_crosscall
NegateTransformSignal Transform
ThresholdCrossSignal Transform
upper0modelong_only
bot_exit_flipstore
TradeManagerPosition Manager
entriesbot_entrypricesohlcv_1d
Parallel2 branches
trend_flip
bot_exit_flipload
AboveThresholdFilterSignal Transform
threshold1inclusivetrue
ExitPosition Manager
atr_trail
TrailingStopPosition Manager
atr2.5period14
ExposurePosition Manager
EqualWeightSizerPosition Sizer
target_leverage1max_weight0.2

Explore the settings

precomputed · updates instantly

Adjust a setting to see the exact backtested result, including the ones that lost money.

Complete 12-cell public cross-product on explicit resolved universes.

EMA trend preset
Momentum confirmation
ATR trailing stop
Sharpe
1.15
Return
213.4%
Worst DD
−50.2%
Trades
1,141

At $1,000, these settings' worst historical dip was about $502. You land in the editor with this exact setup. Free account, your own keys.

Compare all 12 settings
EMA trend presetMomentum confirmationATR trailing stopSharpeReturnWorst DDTrades
10/301421.18216.1%−50.5%1,181
10/30142.5default1.15213.4%−50.2%1,141
10/301431.19236.0%−48.8%1,054
10/303020.95131.6%−50.4%883
10/30302.51.24255.6%−49.0%996
10/303031.16224.5%−46.2%944
20/501420.91116.2%−61.5%989
20/50142.50.87108.4%−65.2%985
20/501430.96137.6%−60.8%861
20/503020.6351.0%−69.0%687
20/50302.50.87105.7%−65.7%745
20/503030.87108.8%−64.0%714

The data

Monthly returns

MonthReturn
2024-080.0%
2024-09+23.1%
2024-10+1.1%
2024-11+66.5%
2024-12-22.7%
2025-01-1.8%
2025-02-17.4%
2025-03-7.1%
2025-04+46.0%
2025-05+2.7%
2025-06-8.0%
2025-07+19.9%
2025-08-4.9%
2025-09+13.3%
2025-10-24.8%
2025-11-0.7%
2025-12-0.3%
2026-01-11.5%
2026-02+1.9%
2026-03-2.6%
2026-04+16.3%
2026-05+35.1%
2026-06-16.6%
2026-07-1.0%
2026-08+32.3%
2026-09+29.9%

Which assets it traded

Avg allocationDays held% of time heldAsset
0.117637748.65BNB
0.111337047.74BTC
0.108435846.19ETH
0.136135345.55HYPE
0.104634144LINK
0.103431941.16SOL
0.105329337.81NEAR
0.104228636.9SUI
0.098428336.52DOGE
0.100625232.52XRP
0.127124932.13VVV
0.115122228.65FARTCOIN
0.091321928.26kPEPE
0.08119024.52kBONK
0.0918624WLD
0.125517522.58ZEC
0.113813217.03PUMP
0.127712816.52LIT
0.135510313.29XPL
0.0502111.42GRAM

What this is: a historical backtest on real Hyperliquid market data, net of fees, slippage, and funding. Its worst historical drawdown was 50.2%. Expect drawdowns of that order or worse. Past performance does not predict future results, and this is not investment advice. Size your account so a full drawdown is survivable.

Questions

Common questions

Does an AI trading bot actually work on crypto?

Over 2024-08-15 → 2026-09-29 on real Hyperliquid perps, the default settings earned a Sharpe of 1.15 with +213.4% total return and a 50.2% worst drawdown across 1,141 trades, net of fees, slippage, and funding. It is a high-drawdown strategy, so size it accordingly.

Best trend-following bot rules for Hyperliquid perps

You can adjust ATR trailing stop, EMA trend preset, Momentum confirmation. The config explorer on this page lets you compare every setting we tested, including the ones that underperformed, with the exact backtested result for each.

Is this an AI trading bot?

No. Its rules are fixed: a moving-average trend filter, a momentum check, a funding filter and a trailing stop sized by volatility. Nothing in it learns or predicts. It is the kind of bot people ask an AI to build, and an AI assistant is a good way to write, change and test rules like these.

Can an AI build a bot like this for me?

Yes. Describe the rules in plain words to an AI assistant connected to Keel, and it can write the strategy and run the backtest. You read the result first, and nothing trades until you deploy it on your own Hyperliquid account.

Related strategies

Which strategy did best on each coin →