# Settlement Mechanics

This document explains exactly what happens at each Hyperliquid funding settlement. What is calculated, who pays whom, and how it affects your position.

## What a settlement is

A funding settlement is a periodic cash transfer between the long and short sides of a perpetual market. It is automatic. You do not sign anything. You do not claim anything. At the exact settlement time, Hyperliquid's protocol calculates the payment and adjusts margin balances.

On Hyperliquid, this happens every **60 minutes**, 24 times per day.

## The settlement calculation

At each settlement:

1. Hyperliquid calculates the **funding rate** for the completed period. This is based on the time-weighted average premium between the perpetual mark price and the oracle (spot) price during that hour.
2. For every open perpetual position:

* **Long positions** pay or receive: `position_size_usd × funding_rate`
* **Short positions** receive or pay: `position_size_usd × funding_rate`

3. If the funding rate is **positive**:

* Longs pay shorts
* Long margin decreases by the payment amount
* Short margin increases by the payment amount

4. If the funding rate is **negative**:

* Shorts pay longs
* Short margin decreases
* Long margin increases

The funding rate is applied to the **notional value** of the position. Not the margin. A $10,000 short position at a 0.01% hourly rate receives $1 per hour, regardless of how much margin is collateralizing that $10,000.

## Effect on delta-neutral positions

In a delta-neutral position (short perp + long spot), only the perp leg participates in funding settlement. The spot holding does not receive or pay funding. It is simply a price hedge.

When positive funding settles:

* Your short perp margin increases by `position_size × rate`
* Your spot position is unaffected
* Net result: pure yield credited to your account every hour

This is the fundamental mechanism of delta-neutral funding rate farming. The settlement credit is free cash. Not contingent on price, not correlated with market direction.

## Timing

Hyperliquid settlements occur at the top of every hour: 00:00, 01:00, 02:00... UTC (verify current settlement times in the Hyperliquid UI, as UTC alignment may vary).

Zirodelta's Market Stats bar shows a **live countdown to the next settlement**. The funding rate displayed is the predicted rate for the upcoming settlement period. The actual settled rate may differ slightly based on the final hour's average premium.

## Predicted vs. Settled rate

Hyperliquid publishes a predicted funding rate in real time. This is an estimate of what the settlement rate will be based on the current premium. It updates continuously via WebSocket.

The predicted rate is what Zirodelta's Realtime chart displays and what feeds the Farm Score calculation. The settled rate (what you actually receive) is the final calculation at the close of the period.

In practice, the settled rate closely tracks the predicted rate in normal market conditions. Significant divergence can occur if the mark price moves sharply in the last few minutes of the settlement period.

## Historical data

Zirodelta tracks every Hyperliquid funding settlement since 2024. The dataset includes:

* 9.4M+ settlements across all markets
* 90-day rolling history per coin
* Stored in ClickHouse with <10ms query latency

You can explore historical settlement data at [zirodelta.com/rates](https://zirodelta.com/rates). The 90-day chart shows the distribution of settled rates, which is useful for understanding typical rate ranges before entering a position.

## What happens to your position at settlement

Your position is not closed or modified at settlement. Settlement is purely a cash flow event. Margin is adjusted, and the position continues unchanged. You continue holding your short perp (and long spot) and receive the next settlement one hour later.

Positions accumulate yield over time through repeated hourly settlements. The Funding History tab in the Portfolio section shows your full settlement history for each position.

> **See also:** [Funding Rates on Hyperliquid](/hyperliquid/funding-rates.md) · [Delta-Neutral Explained](/autopilot/delta-neutral-explained.md)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.zirodelta.com/hyperliquid/settlement-mechanics.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
