How to Build a Hyperliquid Tax Report Tool
Build a Hyperliquid tax report tool: every trade, fee, funding payment, deposit and transfer for a wallet, and where each source's history stops. Tested.

At tax time, a Hyperliquid trader needs a full list of what happened in the year: every trade with its fee, every funding payment, every deposit, withdrawal and transfer. For our test wallet, Hyperliquid's API returned 38,702 fills and stopped in late August, though the wallet had been trading since April. A report built from it would be missing about four months of trades, with no error to say so.
Crypto tax software usually gets that from an exchange export. Hyperliquid's own app has no full-year export (its docs point to a third-party exporter), but every one of those events is public, so a tool can build the report from a wallet address.
Why build a crypto tax report tool on Hyperliquid?
• The records pile up fast. Our test wallet, active since April, had 159,800 fills and 25,689 hourly funding payments.
• Funding makes it worse. It's a payment every hour for every open position, and every one has to be in the report.
• No exchange keys to chase. Users paste a wallet address; there are no read-only API keys to create, expire or debug.
The hard part isn't the format. It's making sure nothing is missing, because each kind of event comes from a different request, and each request stops at a different point in the past.
Four requests, four cut-off dates
| What | Official request | How far back (official) | Hydromancer |
|---|---|---|---|
| Trades and fees | userFillsByTime | A wallet's most recent fills only | From 28 July 2025 |
| Funding | userFunding | Long; rows older than about a week merged per day | Hourly rows |
| Deposits, withdrawals, transfers | userNonFundingLedgerUpdates | Back to the account's first deposit (December 2023 for an older account we checked) | From 28 July 2025 |
| Vault moves | Same ledger request | Same | Same |
Once you have the four, your tool sorts every row into the categories a tax professional asks for:
• Closed trades. Each fill carries closedPnl, the realized gain or loss, and fee. Perps and spot sells both land here.
• Funding. Hourly payments received or paid, kept separate from trading gains. Each row's amount is delta.usdc, positive when received.
• Fees. Trading fees, including any builder fees, as their own total.
• Rewards. Staking rewards from Hyperliquid's delegatorRewards (and delegatorHistory for delegation changes), whichever API you use for the rest; vault payouts from the ledger.
• Transfers. Deposits, withdrawals and moves between your own accounts, which aren't gains at all and must not be counted as one. Each ledger row names its kind in delta.type (deposit, withdraw, send, spotTransfer and so on); for a send, compare user and destination with the wallet to see which way the money went.
How each category is taxed is a question for a local professional. Your tool's job is to make the categories complete and add up.
Pull a full year of trades, funding and transfers
Both versions run the same loop over the three requests a report needs, paging forward from 365 days ago until nothing new comes back.

Hyperliquid API
With a pause between pages so a big wallet doesn't use up the IP's rate limit:
import json, time, requests
URL, H, PAUSE = "https://api.hyperliquid.xyz/info", {}, 5 # stay in budget
USER = "0x77ee3604adbdefa66a817b3cf776412a6613a018"
for kind in ["userFillsByTime", "userFunding", "userNonFundingLedgerUpdates"]:
rows, start = {}, int(time.time() * 1000) - 365 * 86400000
while True:
page = requests.post(URL, headers=H, json={
"type": kind, "user": USER, "startTime": start}).json()
new = {json.dumps(r, sort_keys=True): r["time"] for r in page}
if not new.keys() - rows.keys():
break
rows, start = rows | new, page[-1]["time"]
time.sleep(PAUSE)
print(kind, len(rows), "rows since", time.ctime(min(rows.values()) / 1000))A full page of 2,000 fills weighs 120, so for steady paging a pause of 6 seconds or more keeps you under 1,200 a minute. Our 5-second run stayed inside because each request also takes time.
userFillsByTime 38702 rows since Sat Aug 22 13:10:02 2026
userFunding 1800 rows since Thu Apr 30 08:00:00 2026
userNonFundingLedgerUpdates 103 rows since Thu Apr 30 08:15:05 2026Hydromancer API
The same loop with the address changed and no pause:
import json, os, time, requests
URL, PAUSE = "https://api.hydromancer.xyz/info", 0
H = {"Authorization": "Bearer " + os.environ["HYDROMANCER_API_KEY"]}
USER = "0x77ee3604adbdefa66a817b3cf776412a6613a018"
for kind in ["userFillsByTime", "userFunding", "userNonFundingLedgerUpdates"]:
rows, start = {}, int(time.time() * 1000) - 365 * 86400000
while True:
page = requests.post(URL, headers=H, json={
"type": kind, "user": USER, "startTime": start}).json()
new = {json.dumps(r, sort_keys=True): r["time"] for r in page}
if not new.keys() - rows.keys():
break
rows, start = rows | new, page[-1]["time"]
time.sleep(PAUSE)
print(kind, len(rows), "rows since", time.ctime(min(rows.values()) / 1000))userFillsByTime 159800 rows since Thu Apr 30 08:48:04 2026
userFunding 25689 rows since Thu Apr 30 09:00:00 2026
userNonFundingLedgerUpdates 103 rows since Thu Apr 30 08:15:05 2026How we tested. Our prototype collected one active wallet's tax year (here, the last 365 days) of trades, funding payments and ledger events, once per API, on 31 October 2026. This is about collecting the data, not tax advice. The snippets are prototypes that prove each step works, not an app to copy as is; the request bodies and URLs are exact.
Side by side
| Hyperliquid API | Hydromancer API | |
|---|---|---|
| Trades found | 38,702, back to 22 Aug | 159,800, back to 30 Apr |
| Funding rows | 1,800 (older ones merged per day) | 25,689 (one per payment) |
| Ledger events | 103 | 103 |
| Time | 135 s | 26 s |
| Requests | 28 | 98 |
| Rate-limit cost | 2,615 weight of 1,200/min per IP | 980 points of 20,000/min (Growth plan) |
Both versions work, and the ledger and funding agree: the same 103 ledger events, and funding totals that match to the cent ($117,713.02 on both). Hyperliquid merges funding older than about a week into one row per coin per day, so you lose the hour of each payment, not the money. If your users' rules need each payment with its time, use the hourly rows.
Trades are where they part. This wallet's first ledger event was a deposit in late April. Hydromancer returned 159,800 fills going back to it. Hyperliquid stopped in late August after 38,702: its fill requests only reach a wallet's most recent fills, and this wallet trades too much for that to cover the year. A report built from it would be missing about four months of trades without any error to say so. Hydromancer's history covers most traders but leaves out some very high-volume addresses, so check the trade counts for your heaviest users.
Each fill carries the fee and the token it was paid in (feeToken), so don't assume USDC. Spot pairs show as @ plus an index; look the name up in spotMeta.
Without Hydromancer, a year of history for an active trader comes from Hyperliquid's S3 archive (node_fills_by_block, raw files you download and index yourself) or from Reservoir's daily fill files (free from August 2025, you pay only AWS download charges; the trading journal guide compares both).
Ledger history: Hyperliquid goes further back
Hyperliquid API
For an account opened in December 2023, userNonFundingLedgerUpdates returned all 416 non-trade events back to that month: deposits, withdrawals, transfers, vault deposits and staking. Responses hold up to 500 rows, so page with startTime as the prototype does.
Hydromancer API
The same request covers the same events, but Hydromancer's history begins on 28 July 2025, so it started in August 2025 for that account.
Side by side
| Hyperliquid API | Hydromancer API | |
|---|---|---|
| Ledger for an account opened in Dec 2023 | Back to Dec 2023 (416 events) | Back to Aug 2025 |
| Ledger for our year-long test wallet | 103 events | The same 103 |
For a multi-year report, take the ledger from Hyperliquid.
Checking the report adds up
Before giving users a report, reconcile it: starting balance plus deposits, minus withdrawals, plus realized PnL, plus funding, minus fees, plus rewards and the unrealized PnL of open positions should land near today's balance. A gap means a missing event type, usually a transfer between sub-accounts or a vault move. Hyperliquid's portfolio request has account value history to compare against.
A report that reconciles is the one users trust enough to pay for, usually per report or per tax year. Keep the wallet address private and don't store more than you need.
FAQ
Does Hyperliquid have a tax export?
Not in its own app. Hyperliquid's docs link a third-party exporter (Enigma's trade export). A tool can also combine fills, funding and ledger updates from the API, which is what this guide does.
Why can't I get a year of trades from Hyperliquid's API?
Because fill requests stop at a wallet's most recent fills. For our test wallet that meant 38,702 fills, missing about four months of its trading, from late April to late August. The prototype above shows how to fill the gap.
How do I do my Hyperliquid taxes?
Start with a complete record of the year: every trade with its fee, every hourly funding payment, and every deposit, withdrawal and transfer. Hyperliquid's app doesn't export that, so use a tool built on the API (like the one in this guide) or a crypto tax service that supports Hyperliquid, and check its totals against your account. How each item is taxed depends on where you live, so take the record to a tax professional.
Is funding taxable?
That depends on where you live. We cover how to get the data, not how it's taxed.
Related reading
• How to get a Hyperliquid wallet's trade history
• How to build a trading journal for Hyperliquid
• Hyperliquid fees and revenue
• Download Hyperliquid historical data free (S3 archive)
Sources
- Hyperliquid docs: Info endpoint, Historical data
- Hydromancer docs: Tax and compliance tools guide, userFunding
Read next

How to Build a Hyperliquid TWAP Execution Tool
Build a TWAP execution tool on Hyperliquid: native TWAP orders vs your own slicing, tracking slice fills, and seeing every active TWAP in a market.

How to Build a Trading Terminal on Hyperliquid
Build a Hyperliquid trading terminal: charts, order book, trades and order entry, plus 1-second candles and older chart history. Tested on both APIs.

How to Build a Trading Journal for Hyperliquid
Build a Hyperliquid trading journal: turn fills into closed trades with entry, exit, fees, funding and hold time, and keep history past 10,000 fills.