ZYNCALGO
Home Trading Accounts
Interactive Demo & Complete Guide

ZYNCALGO

Discipline Over Luck
v11 Β· ZyncAlgo Β· Discipline Over Luck
What is ZyncAlgo?
A single-file Python/Flask trading app integrated with Zerodha Kite Connect. 19,618 lines of code, runs locally on your computer, opens in any browser.

🎯 Built for Indian F&O + Equity Intraday Trading

6 scanners · 7 signal types · Stealth SL invisible to operators · Auto-pyramid scaling · Cross-exchange NSE→BSE momentum capture · Real-time WebSocket ticks · ZyncAlgo compounding tracker

πŸ“Š All 10 Pages

🏠 HomeπŸ” Scanners⭐ WatchlistπŸ“ˆ F&O
πŸ“Š Dashboardβš™οΈ SettingsπŸ§ͺ Backtest🎯 Expiry Day
πŸ† ZyncAlgoπŸ“‰ Analytics

⚑ Session 19 Highlights

β€’ F&O Tab rebuilt β€” Directional Overnight + Calendar Spread with auto-order
β€’ Backtest rebuilt β€” overnight strategies with signal mode toggle
β€’ Security hardening β€” Session + CSRF + Rate Limiting on 6 trading routes
β€’ Analytics page β€” win/loss analysis, daily P&L, hourly breakdown
β€’ Session recorder β€” survives app restarts (append, not overwrite)
β€’ Instruments 2x faster β€” removed unused exchanges, threading lock
‒ MARKET→LIMIT auto-convert — Kite API compatibility fix
β€’ IP whitelist popup β€” easy copy when Kite blocks your IP
β€’ VWAP fix β€” correct calculation for index candles (no volume)
β€’ 982 lines cleaned up, 20+ bugs fixed

DISCIPLINE OVER LUCK
Trading as a Habit, Not a Gamble Β· Precision at the Speed of the Market

🎯 The Mission: Ending the Gambling Cycle

In the high-stakes world of Nifty and Bank Nifty options, the line between trading and gambling is thin. Most retail traders fail because they lack the discipline to stop, the speed to exit, and the emotional detachment to win.

ZyncAlgo was created to solve this. We are a high-frequency execution engine that replaces human emotion with algorithmic logic. Our system doesn't "bet" β€” it executes. By automating the journey from entry to exit, we help traders build the Habit of Profitability.

⚑ Why ZyncAlgo?

Hard-Coded Discipline: Our algorithms follow strict risk-management protocols. No revenge trading, no over-leveraging.

Scalping Precision: Optimized for the "β‚Ή5 to β‚Ή50" moves, capturing momentum before the retail crowd can react.

The Anti-Gambling Filter: Every trade is backed by data, ensuring your capital is treated like a business asset, not a casino chip.

⚠️ RISK WARNING & MARKET REALITY

Trading in F&O (Nifty/Bank Nifty) involves significant risk. Statistically, 9 out of 10 individual traders in India lose money. At ZyncAlgo, we do not promise "99% accuracy."

Success Benchmark: Professional systems operate at a 50% to 60% win rate. Success comes from winning big and losing small.

The 20% Capital Rule: We strictly advise never deploying more than 20% of your total capital in a single session.

Strict Discipline: Automated Stop-Losses (SL) are mandatory. Our system is built to protect your survival in the market.

βœ… The "ZYNC" Trading Checklist

1. Capital Shield: Is only 20% of my total capital deployed?

2. SL Verification: Is the hard stop-loss active and "Zynced"?

3. Reality Check: Am I prepared for a 50/50 win rate today while letting winners run?

🎨 Visual Identity

Electric Blue #007BFF β€” Technology & Trust
Neon Green #39FF14 β€” Growth & Profits
Charcoal #36454F β€” Authority & Discipline
πŸ“¦ Installation

One-Click Install (Windows)

πŸ“ ZyncAlgo/
β”œβ”€β”€ INSTALL.bat                  Master installer (double-click!)
β”œβ”€β”€ python-3.12.7-amd64.exe     Python runtime
β”œβ”€β”€ zyncalgo.py              19,618 lines Β· 10 pages Β· 63 routes
└── start_zyncalgo.bat       Daily launcher (port 7777)

Double-click INSTALL.bat β†’ installs Python β†’ installs deps β†’ creates C:\ZyncAlgo β†’ desktop shortcut β†’ done.

Daily Flow

ZyncAlgo shortcut
β†’
Enter password
β†’
Login to Kite
β†’
WebSocket auto-starts
β†’
Trade

Requirements

Kite Connect paid plan β‚Ή500/month (includes REST + WebSocket + Historical). Python 3.10+. Windows 10/11 (64-bit). License key + activation code from admin.

πŸ” 6 Scanners

1 Volume Spike

Vol 4Γ— base + price >0.5%. Catches institutional activity.

2 PDH/PDL Breakout

Breaks previous day high (BUY) or low (SELL).

3 RSI Reversal

RSI proxy <25 BUY (oversold), >75 SELL (overbought).

4 VWAP Cross

LTP crosses VWAP with momentum. Real VWAP from Kite 5-min candles.

5 Gap Up/Down

Open >1% above/below previous close.

6 Cross-Exchange NEW

NSE→BSE momentum gap detection. Gap duration tracker. 40 stocks monitored on both exchanges.

πŸ” Run All Scanners

One click scans all 6 strategies. Multi-confirmed stocks (detected by 2+ scanners) highlighted at top.

🎯 Expiry Day Station
IndexDayExchangeHeavyweights
NIFTYTuesdayNFORIL + HDFC
SENSEXThursdayBFORIL + TCS
BANKNIFTYLast TueNFOHDFC + ICICI

7 Signal Types

CodeSignalTrigger
SFPPCR ExtremePCR <0.7 or >1.3
OB-TOI Wall TouchSpot near OI wall
VWAP-RVWAP RejectionSpot at Β±2Οƒ band
VWAP-XVWAP CrossMean reversion
PH-MOMPower Hour30-min momentum direction
IDCMax Pain DriftToward max pain
0DTE-BBreakoutOpening range break

Signal Strength: 5-Factor Scoring (0-10)

PCR (0-2) + OI Wall (0-2) + VWAP (0-2) + Institutional Flow (0-2) + Session (0-2) = ●●●●○○○○○○

Goldilocks 5-Check (Gamma Blast)

Box formation βœ“ Volume dry-up βœ“ Displacement candle βœ“ Heavyweight check βœ“ FVG detection βœ“ β†’ Trade locked until 4/5 pass.

πŸ›‘ Stealth SL β€” Live Simulation
Click "Start Trade" to see stealth SL + trailing in action.
NIFTY 22700CE β–² BUY 20u @ β‚Ή45.00 β‚Ή0.00
LTP: β‚Ή45.00 πŸ›‘ Stealth β‚Ή40.50 TGT: β‚Ή58.50
Click Start Trade to begin simulation

How Stealth SL Works

Kite order book: BUY 20 CE @ β‚Ή45  ← only this visible
SL order: NONE ← operators can't see

App watches via WebSocket (every 2-5ms):
  πŸ›‘ Stealth: SL β‚Ή40.50 (invisible)
  πŸ”’ 1.5% profit β†’ SL moves to β‚Ή45.00 (breakeven)
  🟒 3% profit β†’ SL trails at entry + 50% peak
  🟒 5% profit β†’ SL trails at entry + 70% peak

WebSocket reaction: ~50ms (was 1,000ms with REST)

Coverage: All 3 Trading Tabs

TabStealth SLTrailAuto-Exit
Expiry / Daily Scalpβœ…βœ… 3-levelβœ… WebSocket
Pyramid (all levels)βœ…βœ… Tableβœ… All levels
Scalp Station (equity)βœ…βœ… 3-levelβœ… WebSocket
πŸ”Ί Pyramid Trading
Available on ANY signal. User confirms Seed, app auto-places L2/L3 when triggers hit.

Pyramid Structure

LevelTriggerWhoShows
L1 SeedCurrent LTPYou (manual click)Capital β‚Ή + Risk β‚Ή
L2 AddLTP Γ— 1.3 (30%)App (auto)Capital β‚Ή + Risk β‚Ή
L3 BoostLTP Γ— 1.8 (80%)App (auto)Capital β‚Ή + Risk β‚Ή

Auto-Pyramid Flow

You click Seed
β†’
LTP hits 1.3Γ—
β†’
App auto-adds L2
β†’
LTP hits 1.8Γ—
β†’
App auto-boosts L3
β†’
Trail SL protects all

Sound + desktop notification on each auto-add. Toggle [βœ“ Auto L2/L3] to disable.

Risk Display

Each level shows Capital β‚Ή + Risk β‚Ή. Total "Max Risk" card in summary. Recalculates instantly when multiplier changes.

⚑ Cross-Exchange Scanner
NSE→BSE momentum capture. Compares speed of price change, not static gap.

How Momentum Comparison Works

Tick 1: NSE β‚Ή142.30, BSE β‚Ή142.30  (baseline stored)
Tick 2: NSE β‚Ή142.80, BSE β‚Ή142.40  (compared)

NSE moved: +0.35% in 5s  ← FAST
BSE moved: +0.07% in 5s  ← SLOW
Momentum gap: 0.28%       ← BSE still catching up

β†’ BUY on BSE @ β‚Ή142.40, Target β‚Ή142.80

Gap Duration Tracker

Measures how long each gap stays open. After 30-60 minutes:

StockAvg GapGapsWin RateVerdict
COALINDIA3.8s1575%βœ… TRADEABLE
GAIL2.2s1062%βœ… TRADEABLE
TATAMOTORS1.1s855%⚠️ BORDERLINE
RIL0.1s2040%❌ TOO FAST

Best Windows

Expiry days 2:00-3:30 PM = biggest gaps (gamma squeezes). Opening 9:15-10:00 = second best. 40 stocks monitored on NSE+BSE simultaneously.

πŸ”Œ KiteTicker WebSocket
Auto-starts on login. 83+ symbols streaming. REST polling as automatic fallback.

Speed Comparison β€” Click to Animate

Stealth SL (REST)
 
1,000ms
Stealth SL (WS)
 
50ms
Cross-Exch (REST)
 
700ms
Cross-Exch (WS)
 
5ms
LTP Display (REST)
 
700ms
LTP Display (WS)
 
100ms

Architecture

Kite Exchange
β†’ 2ms β†’
KiteTicker WS
β†’ 1ms β†’
Python Backend
β†’ SSE β†’
Browser
β†’ 1ms β†’
SL Check

Total: ~50ms end-to-end. If WS disconnects β†’ REST at 700ms resumes automatically.

⚑ Cross-Exchange: WS LIVE Mode

When WebSocket connected: CX scanner shows badge "WS LIVE" β€” ticks compared at 2-5ms. Display refreshes every 200ms. Zero Kite API calls.
When WebSocket not connected: falls back to REST polling every 700ms.
⏺ Record button blocked when market closed (Mon-Fri 9:15-15:30 only).

πŸ“Š CX Replay in Backtest Tab

After recording, go to Backtest tab β†’ scroll down β†’ select tick log β†’ click β–Ά Analyze.
Shows: CX stock verdicts (βœ…/❌), options movement, hourly breakdown, your trade events β€” all in-app, no terminal needed.

API Routes

RoutePurpose
POST /api/ws/startStart WebSocket
POST /api/ws/stopStop WebSocket
GET /api/ws/statusConnection status
GET /api/ws/streamSSE real-time ticks
GET /api/ws/cx-signalsCross-exchange signals
πŸ”Š Notification Sounds β€” 12 Distinct Patterns
Click each card to hear the UNIQUE sound. Each scenario has its own rhythm, pitch, and feel.
πŸ“ˆ
BUY Signal
Quick high double-beep
2 notes Β· 880β†’1100Hz
πŸ“‰
SELL Signal
Quick low double-beep
2 notes Β· 440β†’350Hz
πŸ“€
Order Confirmed
3-note ascending chime
do-re-mi Β· sine
🎯
Target Hit!
5-note celebration melody
C-E-G-C'-E' Β· major
πŸ›‘
Stealth SL Hit
Long low warning buzz
220Hz Β· sawtooth Β· 0.5s
🟒
Trail SL Hit
Soft 3-note descend
mi-do-la Β· gentle
πŸ”’
Breakeven Exit
Neutral click
square Β· 30ms Β· neutral
⚑
Pyramid Auto-Add
Rapid triple-ding up
700β†’900β†’1100Hz Β· fast
πŸ’₯
Pyramid All-Exit
4-note descending alarm
square wave Β· urgent
πŸ”„
Cross-Exchange Gap
Ping-pong alternating
800↔600↔800β†’1000Hz
πŸ“‘
Desktop Notification
Gentle bell
triangle Β· 1200Hz Β· soft
⚑
WS Instant Exit
Sharp snap
2000Hz square Β· 30ms
⏺ Tick Recorder & Replay
Record every WebSocket tick at millisecond resolution. Replay after market to validate strategies.

⚑ Why Not 1-Min Candle Backtest?

MethodResolutionGap DetectionSL Timing
Kite Historical (1-min candles)60,000msMisses sub-minute gapsCan't measure
Live Tick Recording2-5msEvery gap capturedExact ms timing

πŸ“‚ How Recording Works

on_ticks callback (2-5ms):
  β†’ check SL         0.1ms  (unchanged)
  β†’ check CX         0.1ms  (unchanged)
  β†’ buffer.append    0.001ms ← ONLY addition

Separate flush thread (every 5s):
  β†’ writes buffer to CSV
  β†’ zero impact on trading speed

File: tick_log_2026-04-08.csv (~5MB/hour)
  timestamp_ms, symbol, exchange, ltp, volume
  1712568900123, COALINDIA, NSE, 412.50, 15200
  1712568900125, COALINDIA, BSE, 412.35, 3100

πŸ”„ 4-Part Replay Analysis

#AnalysisWhat You Learn
1Cross-Exchange GapsWhich stocks have capturable NSE→BSE gaps? Win rate?
2Options MovementCE/PE range, max 1s move, tradeable options
3Your TradesSL reaction time (ms), target hits, strategy validation
4Tick Speed StatsTicks/sec, per-symbol frequency, fastest gaps

πŸ“… Weekly Plan

Tue: Record NIFTY expiry
β†’
Tue PM: Replay
β†’
Thu: Record SENSEX
β†’
Thu PM: Replay
β†’
Fri: Compare & decide

β–Ά How to Use

During market (Mon-Fri 9:15-15:30 only):
  Login β†’ Nav shows [⏺ Record] β†’ Click it
  Button turns red: [⏹ Recording…]
  Trade normally (zero speed impact)
  Click ⏹ to stop anytime
  ⚠️ Record blocked outside market hours

After market β€” TWO options:
  Option A (in-app): Backtest tab β†’ scroll down
    β†’ Select tick log β†’ Click β–Ά Analyze
    β†’ Full analysis right inside the app

  Option B (terminal): python cx_tick_replay.py
    β†’ Auto-detects latest tick_log file
    β†’ Prints full 4-part analysis

πŸ’‘ Pro Tips

β€’ Open Expiry tab during recording β†’ CE/PE symbols auto-subscribe to WebSocket β†’ captured in tick log
β€’ Record at least 30 min for meaningful data (1 hour ideal)
β€’ SL/Target events auto-logged to separate _trades.csv
β€’ Compare Tuesday vs Thursday to find best expiry patterns
β€’ File size: ~5MB/hour β€” tiny, keep all recordings

πŸ“ˆ F&O β€” Overnight & Calendar Spread
Two automated strategies for pre-expiry overnight trades. Institutional flow analysis drives the signals.

πŸŒ™ Directional Overnight

Single-leg option trade held overnight before expiry day.
Signal based on institutional flow: LONG_BUILDUP β†’ BUY CE, SHORT_BUILDUP β†’ BUY PE, etc.
Auto-populated instrument with strike, lot size, expiry.
One-click Trade Now β€” auto-converts MARKET to LIMIT with 0.5% buffer.

πŸ“… Calendar Spread

Two-leg cross-index strategy: near-expiry (high gamma) + far-expiry (hedge).
Example: BUY NIFTY 24000PE (Mon expiry) + BUY SENSEX 77500CE (Thu expiry).
Near leg profits from big move, far leg limits loss if wrong.
One-click Place Calendar Spread β€” places both legs sequentially with 1s delay.
Safety: if near leg fails β†’ far leg NOT placed.

Signal Engine (6 conditions)

LONG_BUILDUP + market up→ BUY CE
LONG_BUILDUP + market down→ BUY CE (contrarian)
SHORT_BUILDUP + market down→ BUY PE
SHORT_BUILDUP + market up→ BUY PE (contrarian)
LONG_UNWINDING + market up→ BUY PE (fade)
SHORT_COVERING + market down→ BUY CE (bounce)
πŸ“‰ Trade Analytics
Performance tracking with smart insights. Bifurcates app trades vs manual trades. Auto-reconciles with Kite.

Stats Dashboard

Total TradesClosed CountGross P&LWin Rate %
Average WinAverage LossProfit FactorToday's P&L (Kite)

App vs Manual Trade Bifurcation

Every position is automatically tagged:
β€’ APP β€” trades placed via ZyncAlgo (matched from trade log)
β€’ MANUAL β€” trades placed directly in Kite
Separate P&L tracking for each β€” know exactly which source is profitable.

πŸ“Š Smart Insights & Suggestions (8 types)

β€’ πŸ† Win Rate β€” strong / average / low assessment
β€’ βœ… Risk:Reward Ratio β€” are your winners bigger than losers?
β€’ ⏰ Best Trading Hour β€” which session makes you money
β€’ πŸ• Worst Trading Hour β€” which session to avoid
β€’ πŸ“‰ Streak Analysis β€” warns after 3+ consecutive losses
β€’ πŸ›‘ Overtrading Detection β€” too many trades in a day?
β€’ ⭐ Best/Worst Symbol β€” which instruments to focus or avoid
β€’ πŸ“… Daily Consistency β€” green days vs red days

Color coded: green = keep doing Β· neutral = improve Β· red = fix this

Visual Charts

β€’ Daily P&L β€” bar chart of last 14 trading days
β€’ Hourly Breakdown β€” P&L by market session
β€’ Top 5 / Worst 5 Symbols β€” performance ranking
β€’ Trade Log β€” last 100 trades with entry/exit/P&L/status

πŸ’° ZyncAlgo
Compounding calculator. Projects your capital growth with daily targets.

Formula (compound within month)

sessionG = 1 + (0.70 Γ— 0.01) - (0.30 Γ— 0.005) = 1.0055
monthlyG = 1.0055^20 = 1.1161 (11.6% per month)
β‚Ή4,200 Γ— 1.1161^n = β‚Ή20 Cr β†’ n β‰ˆ 82 months

Daily Flow

Opening capital β†’ Today's target (+1%) β†’ Trade β†’ P&L vs target β†’ Excess (bank gains) or Shortfall (need more). Banner shows real-time status.

Key Decisions

βœ… P&L from positions (not balance difference)
βœ… Opening = NW - P&L (reliable fallback)
βœ… Same formula on Home page and ZyncAlgo tab
βœ… Holiday detection β€” shows "Market Closed" not β‚Ή0.00
βœ… Login as default page

ZyncAlgo v19 Β· 19,618 lines Β· Built across 19 sessions Β· April 2026
ZYNCALGO Β· Discipline Over Luck
πŸ“ž +91 9986829907
πŸ“ Siri Mane, No 14, 1st Main Road, Doddabidarakallu, Bangalore 560073
Β© 2026 ZyncAlgo Β· zyncalgo.in Β· Trading involves significant risk