A backtest replays your trading rules against markets that have already settled, so you can see how those rules would have behaved before you risk money. For Kalshi's short-dated markets, such as the 15-minute crypto series, a backtest is the cheapest way to find out whether an idea is worth paper trading at all. It is also the easiest place to fool yourself. This guide walks through how to build one honestly and where backtests usually overstate results.
DeskBot for Kalshi runs your own rules on Kalshi's 15-minute markets, with your own account and API key. Try it for $1: first month $1, then $19.99/month, cancel anytime. Card required. Trading can lose money; nothing guarantees profits.
1. Start with settled markets, not just prices
Every Kalshi market ends with a result: Yes or No. A backtest needs three things for each market you test: the time it opened and closed, the prices that were actually available while it was open, and the final result. Kalshi's public API exposes settled markets and historical candlesticks, and our guide to the Kalshi historical data API covers the endpoints and cutoffs. Store everything you pull in a file or small database so every test runs on the same frozen data.
2. Write the rules down before you look at results
Decide the entry rule (for example, "buy the favored side when its ask is at or under my max price with at least 3 minutes left"), the size, and the exit or hold rule first. If you adjust the rules after every run until the numbers look good, you are fitting the past, not testing an idea. Keep a short log of every rule change and why you made it.
3. Charge fees on every simulated fill
Kalshi's trading fee depends on price and contract count, and it is largest near 50c. A strategy that looks slightly positive before fees can be negative after them. Apply the same fee formula to every simulated trade; our Kalshi fees explainer and break-even win rate table show the math.
4. Use the ask you could have paid, not the last price
The most common backtest mistake is assuming you bought at the last traded price or the midpoint. In live trading you buy at the ask, and the size available at that ask may be small. If your data only has candlesticks, assume you paid the worse side of the spread, and skip any market where the book was too thin for your size. Our guide on reading the Kalshi order book explains why the No bid sets the Yes ask.
5. Count losses at their full size
High-priced favorites win often, but one loss can erase many wins. Buying at 90c makes about 10c per contract when right and loses 90c when wrong, so you need a win rate above roughly 90% plus fees just to break even. Report the worst losing streak and the largest single-day loss next to the win rate, not just the total.
6. Split the data and test forward
Build the rules on one stretch of dates, then run them unchanged on a later stretch you never looked at. If results fall apart on the second stretch, the edge was probably noise. After that, paper trade live for a while; our article on paper trading vs live covers why live fills still differ from paper.
7. Log the trades you skipped
A good bot explains why it stayed out of a market: price above the limit, too little time left, a stale order book, or a daily loss pause. Logging skips in the backtest lets you see whether a filter is protecting you or just removing good trades.
A backtest also needs a sizing rule, because the same trades can look great or ruinous depending on stake size. See how to size Kalshi positions with the Kelly criterion for a fee-adjusted approach and the case for fractional Kelly.
Why backtests overstate results
- Fills at prices that were never really available.
- Rules tuned on the same data they are scored on.
- Missing fees, or fees charged at the wrong price.
- Ignoring periods when markets were paused or not listed.
- Survivorship: only testing the coins or series that later became popular.
Where DeskBot fits
DeskBot is a desktop app for Windows and Intel Mac that runs rule-based trading on Kalshi's 15-minute markets from your own account. Every setting in this guide is a visible control: max entry price, minimum time left, stale order book skip, daily loss pause, and a logged reason for every trade and every skip. It also includes combos and parlays, multi-account support and the S2 strategy, and it runs in paper mode until you switch it to live. Pricing is $1 for the first month, then $19.99/month, cancel anytime.
Try DeskBot for $1: first month $1, then $19.99/mo, cancel anytime
Trading can lose money. Past results don't guarantee future results. DeskBot does not promise profits. Not affiliated with Kalshi or Polymarket.