> For the complete documentation index, see [llms.txt](https://docs.koinju.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.koinju.io/exchanges/hyperliquid.md).

# Hyperliquid Spot historical trade data

Hyperliquid Spot historical trade data since 2025-03-22, available through SQL or REST in one unified schema and checked every day against Hyperliquid's own data.

Koinju provides Hyperliquid Spot trades and OHLCV candles for all markets since **2025-03-22**, under the exchange ID `hyperliquid`. This page explains what that gives you compared with Hyperliquid's own API, how we collect the data, and how we verify that no trades are missed.

{% hint style="info" %}
How far back you can query depends on your plan: see [Pricing](/pricing.md). Every exchange and its start date is listed on [Coverage](/data/coverage.md).
{% endhint %}

## Why use Koinju for Hyperliquid data

* **Full history in one place.** Hyperliquid's API has no documented endpoint for past public trades by market, and its trade history is published as raw node data in a cloud storage bucket where the requester pays for transfer costs ([Hyperliquid docs](https://hyperliquid.gitbook.io/hyperliquid-docs/historical-data)). Koinju provides it as one continuous history since 2025-03-22, aligned to UTC days and queryable for any period through SQL or REST.
* **One schema across exchanges.** Unified symbols and columns across every exchange we cover, Hyperliquid included, so the same query works on all of them.
* **Checked against Hyperliquid's own data.** Every day, each market's volume is compared with Hyperliquid's own daily candle and any missing trades are added.
* **Faithful to Hyperliquid.** Hyperliquid's own trade IDs and trade times, with prices and quantities exactly as Hyperliquid publishes them.

## At a glance

| Property              | Value                                                             |
| --------------------- | ----------------------------------------------------------------- |
| Exchange ID           | `hyperliquid`                                                     |
| Historical data since | 2025-03-22                                                        |
| Data types            | Public trades, OHLCV                                              |
| Collected from        | Hyperliquid's real-time WebSocket, trades subscription (`trades`) |
| Volume check          | Every day, against Hyperliquid's UTC daily candles                |

## How we collect Hyperliquid trades

* **Every trade, individually.** We subscribe to Hyperliquid's [trades subscription](https://hyperliquid.gitbook.io/hyperliquid-docs/for-developers/api/websocket/subscriptions) (`trades`) for every Spot market Hyperliquid lists. Each trade update is stored as its own row with Hyperliquid's trade ID.
* **New listings picked up automatically.** The market list is refreshed every minute, and new markets are subscribed without a restart.
* **Active redundancy.** Every market is collected twice, by two collectors running in parallel. If one connection drops, it reconnects and resubscribes automatically while the other keeps collecting trades. Both copies of a trade share one key (exchange, market and trade ID), so the second copy is dropped before storage, and anything missed is recovered by the checks below.
* **Hyperliquid's timestamps.** A trade's `timestamp` is the trade time reported by Hyperliquid, not the time we received it.
* **Exact values.** Prices and quantities are stored exactly as Hyperliquid publishes them, as high-precision decimals with no rounding.

## From Hyperliquid's message to your data

Each trade Hyperliquid publishes is stored as one row, with Hyperliquid's fields mapped to the same columns used for every exchange:

| Hyperliquid field | Koinju column | Notes                                                                         |
| ----------------- | ------------- | ----------------------------------------------------------------------------- |
| `coin`            | `market`      | Koinju's universal symbol, for example `HYPE-USDC`                            |
| `tid`             | `trade_id`    | Hyperliquid's trade ID                                                        |
| `px`              | `price`       | Exact decimal, no rounding                                                    |
| `sz`              | `quantity`    | In the base currency                                                          |
| `side`            | `side`        | `buy` for `B`, `sell` for `A`: the aggressing side, as Hyperliquid defines it |
| `time`            | `timestamp`   | Hyperliquid's trade time                                                      |

## How we verify that no Hyperliquid trades are missed

### Volume check against Hyperliquid's own candles

The reference is Hyperliquid's own daily candle for each UTC day. A daily candle is only final once the day has closed, so each day is checked the morning after, against Hyperliquid's final figures for that day. The daily rhythm follows the reference data rather than an arbitrary time window.

1. **Compare.** Each market's volume for the UTC day is compared with Hyperliquid's daily candle. Markets where our volume is lower than Hyperliquid's go to step 2.
2. **Add.** For those markets, the comparison is repeated hour by hour. The trades of the hours that differ are fetched from Hyperliquid's node data files (`node_fills_by_block`), and only trades we do not already hold are added.
3. **Re-check.** The whole comparison runs again on the updated data, and any difference that remains is flagged for review.

A day is marked as checked only after all three steps complete. If any step fails, the day stays open and is retried on the next run.

## Hyperliquid-specific details

* **UTC daily candles.** Hyperliquid's daily candles (`interval=1d`) start at 00:00 UTC, the same day boundaries as our daily total.
* **The exact figure compared.** The volume check compares the daily candle's `v` field, which Hyperliquid counts in the base currency, with the sum of the trade quantities we hold for that day.
* **Readable Spot symbols.** Hyperliquid's API identifies most Spot markets only by an index, for example `@107` for HYPE/USDC ([Hyperliquid docs](https://hyperliquid.gitbook.io/hyperliquid-docs/for-developers/api/info-endpoint)). We translate each index into the market's token names, so you query `HYPE-USDC` rather than `@107`.
* **Some names differ on Hyperliquid's website.** Hyperliquid's trading website, `app.hyperliquid.xyz`, shows some tokens under a different name than its API: the market shown there as `BTC/USDC` is `UBTC/USDC` in the API. Our symbols use the API names, so that market is `UBTC-USDC`.

## Access Hyperliquid data

* [Public trades](/data/public-trades.md): every trade, through SQL (`api.trade`) or REST, with `exchange = 'hyperliquid'`.
* [OHLCV](/data/ohlcv.md): candles for every market.
* [Market list](/data/market-list.md): all `hyperliquid` markets and their symbols.
* [How to connect](/how-to-connect.md): SQL, REST and client setup.

## FAQ

**Which timestamp does Koinju store?**

The trade time reported by Hyperliquid.

**Which Hyperliquid Spot markets are included?**

Every Spot market Hyperliquid lists. The market list is refreshed every minute, so a new listing is subscribed within a minute of appearing in Hyperliquid's market list.
