How to Backtest a Pool
Use the MaxFi backtest tool to test strategies with real historical data.
Key Takeaways
- The backtest tool shows real historical returns for any pool and settings
- Compare different range widths and rebalance delays to find the best fit
- Past performance helps inform your strategy but does not guarantee future results
What is Backtesting?
Backtesting lets you test a strategy using real historical data. It answers the question: "If I had used these settings over the past year, what would my returns have been?"
MaxFi's backtest tool at maxfi.tech/backtest does exactly this.
How to Use the Backtest Tool
Step 1: Choose a Pool
Select the pool you want to test. The tool supports all MaxFi pools across Uniswap V3, Aerodrome, and PancakeSwap.
Step 2: Set Your Parameters
- Range width: Try different widths to see how they affect returns
- Rebalance delay: Test different wait times
- Time period: Choose how far back to test (7 days, 30 days, 365 days)
- Deposit amount: Set your starting amount
Step 3: Run the Backtest
Click "Run Backtest." The tool calculates:
- Total return (fees earned minus IL)
- Number of rebalances
- Time spent in range
- Comparison to just holding the tokens
Step 4: Compare Results
Try different settings and compare. A wider range with a longer delay might outperform a narrow range with a short delay, or vice versa. The backtest tells you which worked best historically.
What to Look For
Total return: The bottom line. Higher is better, but consider the risk.
Rebalance count: Fewer rebalances generally means lower costs. But too few means you spent too much time out of range.
Time in range: Higher is better. This tells you what percentage of time your position was actively earning.
Tips for Better Backtests
Test multiple time periods. A strategy that works in a bull market might struggle in a bear market. Test both.
Compare range widths. Try 3%, 5%, 10%, and 20%. The best width depends on the pool.
Start with defaults. MaxFi's default settings are already optimized. Use backtests to see how much (if any) improvement you can get by tweaking them.
Remember: Past results do not guarantee future performance. Use backtests as a guide, not a promise.
What You Learned
- The backtest tool shows real historical returns for any pool and settings
- Compare different range widths and rebalance delays to find the best fit
- Past performance is a guide, not a guarantee
Frequently Asked Questions
Is the backtest based on real data?
Does past performance guarantee future results?
Can I backtest any pool?
See how much you could earn.
Run a Backtest →