> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hypedexer.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Leaderboard

> Two modes.

**Window mode** (`window=7d|30d|all`): pre-computed ranking across **every address** that traded in the window, paginated with `page` / `limit` (up to 500 per page). `7d` and `30d` are refreshed every 5 minutes, `all` every hour; each row carries `refreshed_at` (ms). Metrics available: `volume`, `pnl` (net = realized PnL − fees), `trades` (fill count), `win_rate`, `pnl_pct`, `unrealized_pnl`, `priority_fees` (ranked by volume in this mode). `win_rate` = winning round-trip trades / round-trip trades; `pnl_pct` = net PnL / traded volume × 100; `trade_count`, `wins` and `losses` are round-trip trades (a position opened then closed) reconstructed from the fills; `fill_count` is the number of fills. `unrealized_pnl` and `account_value` come from the latest account snapshot (hourly; 0 when the address has no open position). Every row carries `refreshed_at` (ms), the time of the last ranking refresh. Rankings by `win_rate` and `pnl_pct` only include addresses with at least `min_trades` round-trip trades (default 10). `all` covers fills since 2025-03-22.

**Live mode** (no `window`): ranking over the last `hours` hours computed on the fly, top 100 max, metrics `volume`, `pnl`, `trades`, `priority_fees` only.



## OpenAPI

````yaml /api-reference/openapi.json get /users/leaderboard
openapi: 3.0.3
info:
  title: 'Hypedexer API: Indexed Data'
  version: 1.0.0
  description: >-
    API to query indexed Hyperliquid trading data.


    This API provides access to stored/indexed trading data:

    - **Fills**: Executed orders and fills (Spot-only or All = Spot + Perp)

    - **Analytics**: Aggregations and statistics based on indexed data

    - **Completed Trades**: Trade objects and their related fills

    - **Users**: User overviews, performance and activity

    - **Social Trading**: Per-trader equity curve, PnL calendar, account
    leverage and top trades

    - **Funding**: Funding rate history, user funding payments, predicted rates

    - **Liquidations**: Liquidation events with filters

    - **Overview**: Market dashboard metrics (volume, fees, traders, PnL)

    - **Spot**: Spot token metadata, pairs, and auctions

    - **TWAPs**: TWAP orders, execution stats and fills

    - **Vaults**: Vault details, summaries, equity, ledger


    > Note: No live streaming. Responses are computed from indexed data.
servers:
  - url: https://api.hypedexer.com
    description: Production, routed to the nearest region (EU or JP)
security:
  - ApiKeyAuth: []
tags:
  - name: Fills
    description: Fills endpoints.
  - name: Analytics
    description: Aggregations and stats.
  - name: Completed Trades
    description: Trades and fills.
  - name: Users
    description: User profiles.
  - name: Funding
    description: Funding rates and payments (HL-compatible).
  - name: Liquidations
    description: Liquidation events.
  - name: Overview
    description: Market dashboard metrics.
  - name: Spot
    description: Spot token metadata, pairs and auctions.
  - name: TWAPs
    description: TWAP orders, stats and fills.
  - name: Vaults
    description: Vault details, summaries, equity and ledger.
  - name: Social Trading
    description: >-
      Per-trader equity, PnL calendar, performance, account leverage and top
      trades.
  - name: Market history
    description: >-
      Historical Hyperliquid market microstructure: best bid/offer aggregates
      and spread statistics (April 2024 to February 2026), and the order book
      reconstructed minute by minute: April 2024 to February 2026 from our
      archive (top ~20 levels per side) and, since 23 September 2026, the full
      order book replayed from our own node. Served from the EU region.
paths:
  /users/leaderboard:
    get:
      tags:
        - Users
      summary: Leaderboard
      description: >-
        Two modes.


        **Window mode** (`window=7d|30d|all`): pre-computed ranking across
        **every address** that traded in the window, paginated with `page` /
        `limit` (up to 500 per page). `7d` and `30d` are refreshed every 5
        minutes, `all` every hour; each row carries `refreshed_at` (ms). Metrics
        available: `volume`, `pnl` (net = realized PnL − fees), `trades` (fill
        count), `win_rate`, `pnl_pct`, `unrealized_pnl`, `priority_fees` (ranked
        by volume in this mode). `win_rate` = winning round-trip trades /
        round-trip trades; `pnl_pct` = net PnL / traded volume × 100;
        `trade_count`, `wins` and `losses` are round-trip trades (a position
        opened then closed) reconstructed from the fills; `fill_count` is the
        number of fills. `unrealized_pnl` and `account_value` come from the
        latest account snapshot (hourly; 0 when the address has no open
        position). Every row carries `refreshed_at` (ms), the time of the last
        ranking refresh. Rankings by `win_rate` and `pnl_pct` only include
        addresses with at least `min_trades` round-trip trades (default 10).
        `all` covers fills since 2025-03-22.


        **Live mode** (no `window`): ranking over the last `hours` hours
        computed on the fly, top 100 max, metrics `volume`, `pnl`, `trades`,
        `priority_fees` only.
      parameters:
        - name: by
          in: query
          description: >-
            Ranking metric. `win_rate`, `pnl_pct` and `unrealized_pnl` require
            `window`. `priority_fees` (live mode) ranks users by total priority
            gas paid and returns `user`, `total_priority_gas`, `fill_count`.
          schema:
            type: string
            default: volume
            enum:
              - volume
              - pnl
              - trades
              - win_rate
              - pnl_pct
              - unrealized_pnl
              - priority_fees
        - name: hours
          in: query
          description: Lookback window in hours (live mode only, ignored with `window`)
          schema:
            type: integer
            default: 24
            minimum: 1
            maximum: 168
        - name: limit
          in: query
          schema:
            type: integer
            default: 20
            minimum: 1
            maximum: 500
          description: 'Users per page: up to 500 in window mode, 100 in live mode'
        - name: window
          in: query
          description: >-
            Pre-computed ranking across every address, paginated. Omit for live
            mode.
          schema:
            type: string
            enum:
              - 7d
              - 30d
              - all
        - name: page
          in: query
          description: >-
            Page number (window mode). `has_more` and `next_cursor` (next page
            number) tell whether more pages exist; `total_count` is the number
            of ranked addresses.
          schema:
            type: integer
            default: 1
            minimum: 1
        - name: min_trades
          in: query
          description: >-
            Window mode: minimum round-trip trades for an address to appear in
            `win_rate` and `pnl_pct` rankings
          schema:
            type: integer
            default: 10
            minimum: 0
        - name: X-API-Key
          in: header
          schema:
            type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                  message:
                    type: string
                  data:
                    type: array
                    items:
                      type: object
                  total_count:
                    type: integer
                    nullable: true
                  next_cursor:
                    type: string
                    nullable: true
                  has_more:
                    type: boolean
                    nullable: true
              examples:
                window:
                  summary: window=30d&by=pnl&limit=2
                  value:
                    success: true
                    message: Users leaderboard by pnl over 30d
                    data:
                      - user: '0x0a8494f70031623c9c0043aff4d40f334b458b11'
                        fill_count: 185814
                        total_volume: 36485983.030620664
                        realized_pnl: 18201225.47541415
                        fees: 7226.025004460003
                        total_pnl: 18193999.450409688
                        trade_count: 0
                        wins: 0
                        losses: 0
                        win_rate: 0
                        pnl_pct: 49.8657
                        unrealized_pnl: 0
                        account_value: 0
                        rank: 1
                        refreshed_at: 1790617080000
                      - user: '0x30afce2f6842bf183c7e3fe7162e279ff0b6393e'
                        fill_count: 141112
                        total_volume: 123657348.593871
                        realized_pnl: 17050343.954910703
                        fees: 29485.69621788397
                        total_pnl: 17020858.25869282
                        trade_count: 5
                        wins: 2
                        losses: 3
                        win_rate: 0.4
                        pnl_pct: 13.7645
                        unrealized_pnl: 0
                        account_value: 0
                        rank: 2
                        refreshed_at: 1790617080000
                    total_count: 327699
                    execution_time_ms: 139.9
                    next_cursor: '2'
                    has_more: true
                live:
                  summary: by=volume&hours=24 (live mode)
                  value:
                    success: true
                    message: Users leaderboard by LeaderboardMetric.volume
                    data:
                      - user: '0xf5d81a135f756ca16544e53c20fc20643ec3ad53'
                        total_volume: 656195174.1893002
                        fill_count: 182397
                        unique_coins: 18
                      - user: '0xcf3f419d08a5bdc2c6e5fbd9ad70904c5420f95f'
                        total_volume: 464838871.72480077
                        fill_count: 17817
                        unique_coins: 1
                    total_count: null
                    execution_time_ms: 197.79
                    next_cursor: null
                    has_more: null
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        Your Hypedexer API key. Create one in the console at
        https://app.hypedexer.com. `Authorization: Bearer <key>` and the
        `api_key` query parameter are accepted as well.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.