nkaz001/hftbacktest

AlgoScore
58
For research
★5.2k
Forks984
Issues+PR25
Push12 mo
LicenseMIT

Editorial verdict For researchchecked 05.12.2026

What it is good at

One of the few open tools that models what breaks most HFT backtests: the queue position of a resting limit order and the latency of both feed and orders. The order book is rebuilt tick by tick from Level-2 market-by-price and Level-3 market-by-order data, and you can plug in your own latency and fill models. Multiple assets and exchanges run in one simulation. Strategies are written in Python under Numba JIT or in Rust. The documentation is strong, with tutorials on high-frequency grid trading, the GLFT market making model, order book imbalance, latency impact and L3 data. The same strategy code can run as a live bot on Binance Futures and Bybit, in the Rust version only.

Weak spots

The last commit on master is from 23 December 2025, almost a year of silence. Python package 2.4.4 and Rust crate 0.9.4 shipped in December 2025, while fix pull requests (Python 3.14 support, refetching the Binance depth snapshot on a sequence break, truncated snapshots in the Tardis converter) sit unanswered. Recent open issues report best_bid_qty returning the price instead of the quantity and an out-of-bounds read in unsafe Rust code. You also need tick-level order book data, collected yourself or bought from a vendor, at gigabytes per day. The learning curve is steep.

Who it is for

Researchers working seriously on market making and microstructure strategies who are comfortable with tick data and Numba or Rust code. Unnecessary complexity for swing strategies on hourly or daily candles.

Versus alternatives

NautilusTrader is also event-driven, trades live on many venues and is actively developed, but queue position and latency need separate configuration there. vectorbt works on candles and is not built for HFT. On limit order fill realism hftbacktest is among the best open projects; on maintenance activity it currently falls behind.

Security

The Rust live connector uses Binance Futures and Bybit API keys. Create a dedicated trade-only key with withdrawals disabled and an IP whitelist, and run on testnet first. With almost a year without commits, exchange API changes may break the connector.

  • Last commit — 23 Dec 2025
  • PyPI hftbacktest 2.4.4 and Rust crate 0.9.4 — Dec 2025
  • License: MIT
  • Requires Python 3.11+
  • Live trading in Rust only: Binance Futures and Bybit

Stars by day

Our star series started 05.12.2026: the chart appears after the second snapshot.

GitHub dataGitHub ↗

TopicAlgo trading & backtesting
LanguageRust
Created25.08.2022
Last release10.12.2025
Releases / tags41 / —
Contributors25
Commits total / 90d1k / 0
Watchers76

AlgoScore breakdownmethodology →

Popularity15.5/20
Freshness3.2/20
Community11.5/20
Maturity13.5/15
Momentum—
Usage—

Topic neighboursAlgo trading & backtesting →

#RepositoryAlgoScore★30d growthPushLabel
1 nautechsystems/nautilus_traderProduction-grade Rust-native trading engine with deterministic event-driven architecture 90 32k — today Use it
2 vnpy/vnpy基于Python的开源量化交易平台开发框架 87 47k — 24 d
3 coding-kitties/investing-algorithm-frameworkFramework for quantitative trading. Complete framework for development, backtesting, and deploying automated trading algorithms and trading bots. 87 2.3k — 1 d
4 microsoft/qlibQlib is an AI-oriented Quant investment platform that aims to use AI tech to empower Quant Research, from exploring ideas to implementing productions. Qlib supports diverse ML modeling paradigms, including supervised learning, market dynamics modeling, and RL, and is now equipped with https://github 85 51k — today For research
5 QuantConnect/LeanLean Algorithmic Trading Engine by QuantConnect (Python, C#) 85 23k — today Use it
6 pst-group/pysystemtradeSystematic Trading in python 85 3.7k — 33 d
7 stefan-jansen/machine-learning-for-tradingCode for Machine Learning for Trading, 3rd edition — from data sourcing to live execution. 84 22k — today
8 polakowo/vectorbtThe research engine that gives you an unfair advantage. Run thousands of trading ideas before others finish one. 84 10k — 6 d Use it