Skip to content

Crude UI but a ton of information when you enter a wallet including reverse engineering potential strategies.

Notifications You must be signed in to change notification settings

PotluckProtocol/HyperliquidWalletAnalyzer

Repository files navigation

Hyperliquid Wallet Analyzer

A comprehensive trading analytics dashboard for analyzing Hyperliquid perpetual futures wallets. Reverse-engineer any trader's strategy by analyzing their historical trades against technical indicators, candlestick patterns, and market conditions.

Dashboard Preview TypeScript Tailwind CSS

Features

Real-Time Analysis

  • Position Monitoring - Live positions with entry price, PnL, leverage, and liquidation distance
  • Account Metrics - Account value, margin usage, effective leverage, unrealized PnL
  • Risk Assessment - Visual risk gauge with breakdown by leverage, concentration, and liquidation proximity

Strategy Detection

  • Trading Style Classification - Automatically identifies Scalper, Day Trader, Swing Trader, or Position Trader
  • Strategy Identification - Detects Trend Following, Mean Reversion, Breakout, and Reversal strategies
  • Performance Metrics - Win rate, profit factor, average win/loss, and performance grade

Advanced Technical Analysis

  • Timeframe Detection - Determines which candle timeframe (5m, 15m, 30m, 1h, 4h) the trader likely uses
  • Indicator Correlation - RSI, EMA, MACD, Bollinger Bands, VWAP usage patterns
  • Candlestick Pattern Recognition - Detects patterns at entry points (Hammer, Engulfing, Doji, etc.)
  • Support/Resistance Analysis - Identifies key levels and entry proximity

Execution Analysis

  • TWAP Detection - Identifies algorithmic/systematic order execution patterns
  • Bollinger Band Usage - Tracks band touches, squeezes, and %B at entry
  • VWAP Awareness - Detects institutional-style VWAP-based trading

Alerts & Notifications

  • Discord Webhooks - Real-time alerts for new positions, closes, and liquidation risk
  • Telegram Integration - Mobile notifications via Telegram bot

Tech Stack

  • Framework: Next.js 16 (App Router)
  • Language: TypeScript
  • Styling: Tailwind CSS
  • Charts: Recharts
  • Database: SQLite + Prisma
  • Icons: Lucide React

Quick Start

Prerequisites

  • Node.js 20+
  • npm or yarn

Installation

# Clone the repository
git clone https://github.com/yourusername/hyperliquid-analyzer.git
cd hyperliquid-analyzer/dashboard

# Install dependencies
npm install

# Set up the database
npx prisma generate
npx prisma db push

# Start the development server
npm run dev

Open http://localhost:3000 in your browser.

Environment Variables (Optional)

Create a .env file in the dashboard directory for optional features:

# Database (default works out of the box)
DATABASE_URL="file:./dev.db"

# Discord alerts (optional)
DISCORD_WEBHOOK_URL="https://discord.com/api/webhooks/..."

# Telegram alerts (optional)
TELEGRAM_BOT_TOKEN="your-bot-token"
TELEGRAM_CHAT_ID="your-chat-id"

Deployment

Vercel (Recommended)

Deploy with Vercel

  1. Push to GitHub
  2. Import to Vercel
  3. Deploy (zero configuration needed)

Docker

# Build the image
docker build -t hyperliquid-analyzer ./dashboard

# Run the container
docker run -p 3000:3000 hyperliquid-analyzer

Self-Hosted

# Build for production
cd dashboard
npm run build

# Start production server
npm start

Project Structure

hyperliquid-analyzer/
├── dashboard/                 # Next.js application
│   ├── src/
│   │   ├── app/              # App router pages & API routes
│   │   │   ├── api/          # REST API endpoints
│   │   │   │   ├── wallet/[address]/
│   │   │   │   │   ├── route.ts        # Main analysis
│   │   │   │   │   ├── fills/route.ts  # Trade history
│   │   │   │   │   └── strategy/route.ts # Strategy detection
│   │   │   │   └── alerts/route.ts     # Alert management
│   │   │   ├── analytics/    # Analytics page
│   │   │   └── page.tsx      # Main dashboard
│   │   ├── components/       # React components
│   │   ├── lib/              # Core libraries
│   │   │   ├── hyperliquid.ts         # API client
│   │   │   ├── technical-analysis.ts  # TA calculations
│   │   │   ├── trade-context-analyzer.ts # Strategy detection
│   │   │   ├── strategy-detector.ts   # Pattern recognition
│   │   │   └── alerts.ts              # Notification system
│   │   └── types/            # TypeScript definitions
│   └── prisma/               # Database schema
├── analyze_hyperliquid_wallet.py  # Original Python script
└── hyperliquid_wallet_analysis_guide.md  # Analysis framework

API Endpoints

Endpoint Method Description
/api/wallet/[address] GET Full wallet analysis
/api/wallet/[address]/fills GET Trade history
/api/wallet/[address]/strategy GET Strategy detection
/api/alerts GET/POST/PUT Alert configuration

Usage

  1. Enter a wallet address in the search bar (any valid Hyperliquid address)
  2. View real-time metrics - positions, PnL, leverage
  3. Scroll down to see strategy detection and insights
  4. Click "Detailed Analytics" for charts and historical data

Example Wallets to Analyze

You can analyze any public Hyperliquid wallet. The default demo wallet is:

0x833b99b27dac651d02080f5e220e929df891db06

How Strategy Detection Works

  1. Fetches trade history from Hyperliquid API
  2. For each trade entry, fetches candles at multiple timeframes
  3. Calculates indicators at the moment of entry (RSI, EMA, BB, VWAP)
  4. Detects patterns (candlestick patterns, S/R levels)
  5. Scores each timeframe based on how "clean" the setup looks
  6. Aggregates statistics to identify the likely strategy

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

License

MIT License - feel free to use this project for any purpose.

Disclaimer

This tool is for educational and research purposes only. It does not constitute financial advice. Past performance does not guarantee future results. Always do your own research before trading.

Acknowledgments

About

Crude UI but a ton of information when you enter a wallet including reverse engineering potential strategies.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published