Skip to content

Case study · Side project

Backtest Engine

A backtesting app for the Indian stock market. Build a strategy, test it on years of your own broker's data, and let a live scanner watch the market for it.

Tejas Gaware3 min read
A candlestick chart breaking out above a dashed resistance line, with the line Find the breakout before the crowd does
From the app's sign in screen. Find the breakout before the crowd does.

At a glance

  • 5

    broker integrations for market data

  • 10k+

    lines of Rust in the desktop core

  • 2

    stock exchanges covered, NSE and BSE

  • Svelte 5
  • SvelteKit
  • TypeScript
  • Tailwind CSS
  • Chart.js
  • Rust
  • Tauri
  • SQLite
  • DuckDB
  • WebSockets

This is a product I’m building on my own: a place to design a trading strategy, test it against years of real market data, and get told when the market lines up with it. It’s a desktop app, with the heavy lifting done in Rust on your own computer.

I design it, build it and ship it myself. Here’s what it does, and how it works.

The builder

A visual strategy builder

Strategies are designed visually, and the builder turns them into rules a backtest can run.

Strategies come in two modes, intraday and delivery, each with its own rules, and both run on a real backtest engine. A backtest reports profit factor, leverage, per company results and the full trade history behind every number.

The scanner

A scanner that watches for you

A backtest tells you a strategy worked in the past. The scanner tells you when it’s setting up now. It scans a group of companies against your strategy and refreshes live over WebSockets. Click a result and a candlestick chart shows the setup, the breakout and the target, drawn right on the candles.

Around it came the rest of a real product: sign in with secure tokens, alerts and notifications, help docs, and a dashboard that shows the state of everything at a glance.

Analysis

Deeper analysis

The builder supports technical indicators and a position sizing step, and a Strategy Analysis view that compares backtests with profit factor and drawdown charts, filterable by group of companies.

Backtests run in a queue, so long runs never hold up the app.

The desktop app

The engine runs on your computer

It’s a desktop app built with Tauri: the desktop shell, a local SQLite database for strategies and results, a local market data store in DuckDB, and a backtest engine in Rust that reads straight from it.

The engine, the market data and your broker details all live on your machine.

The Rust core holds the backtest engine, the strategy language it runs, the indicators and the scanner, about ten thousand lines in all. Backtests run against data on your own disk, so they’re fast and they work without waiting on a server.

The data

Bring your own data

A backtest is only as good as its data, so the app pulls history straight from your broker. It connects to five Indian brokers: Angel One, Dhan, Upstox, Zerodha and Groww, covering both NSE and BSE.

Syncing years of history from five different APIs takes care. Sync runs in parallel, waits out rate limits and resumes where it stopped. It fills in only the history that’s missing, finds gaps in what it already has, and compares coverage across brokers. A Data page shows exactly what’s stored, for which companies and timeframes, and you can also import CSV files.

Privacy

Private by design

Connecting a broker means trusting an app with your login, so those details are encrypted and never leave your computer. The desktop app signs in to your account, supports password resets, and lets more than one person use the same computer, each with their own data.

Every public page is designed to match: sign in, sign up, password reset, terms, privacy and about. The artwork at the top of this page comes from the sign in screen.

Have a project or a role in mind?

I'm open to full time, contract and part time work. Let's talk.

© 2026 Tejas Vijay Gaware