# Global Funding Rate

#### <mark style="color:orange;">**1. How does the funding rate work under Derivio's universal margin system?**</mark>

In Derivio’s [universal margin system](/v1/trading/perpetual-futures/universal-margin-system.md), we charge/distribute funding for both the token you long and short (e.g. long ETH/BTC = long ETH + short BTC). For each coin we break it down into two parts:

* The long short ratio itself: we look at the OIs of a coin borrowed, versus the OI of all coins borrowed against this particular coin. We set up a threshold, which could be different for different coins, to determine if the market imbalance is significant. The final funding amount will be proportional to the long short percentage after threshold.

$$
\text{Long OI of coin X} = \sum\_{coin Y \in \text{pool}} \text{Long(X) OI of pair X/Y for all Y} \\
\text{Short OI of coin X} = \sum\_{coin Y \in \text{pool}} \text{Short(X) OI of pair Y/X for all Y}
$$

$$
\text{Long %} = \frac{\text{Long OI}}{\text{Long OI} + \text{Short OI}}\\
$$

$$
\text{Short %} = \frac{\text{Short OI}}{\text{Long OI} + \text{Short OI}}
$$

<figure><img src="/files/6Q14jkWD5KCNLLNe4Unq" alt=""><figcaption><p>Funding rate under universal margin system</p></figcaption></figure>

* The borrow rate: If the pool has low open interest, the imbalance might not reflect the real market circumstances. So the borrow rate of the coin acts as a weight to let it more accurately reflect the true situation of the market.

And thus we could apply the formula in the previous section to calculate the funding rate for each coin separately, before adding them together to get the final funding rate.

#### <mark style="color:orange;">**2. Will traders think it’s expensive to trade here because of the funding fee?**</mark>

* Funding fees can be positive or negative; in a market neutral scenario (LP’s exposure), statistically the fees should cancel out each other. From a trader’s perspective, the fee is negligible when he/she trades over a particular market.
* The funding fee is designed to be 0 most of the time, since we start to charge funding fee only when the market is skewed over a threshold (and this threshold is one of the parameters that are tuned differently for different pools). That is, only when trading is unfair between traders and LPs (traders are having cheap counter-parties here), that’s the time we start to charge.
* If, at a point traders still feel too expensive to trade a particular market in a particular direction, that might mean arbitrageurs should step into the opposite direction to collect fundings and correct the imbalance. This can boost the trading volume while maintaining a healthy & fair market at the same time.
* Parameters can be fine tuned for funding rate to make sure it is fair and don’t impact traders’ experience.

#### <mark style="color:orange;">3.</mark> <mark style="color:orange;"></mark><mark style="color:orange;">**What is Sentiment Indicator?**</mark>

We define the Sentiment Indicators for market A/B as &#x20;

Bullish % = Long(A) % / (Long(A) % + Long(B) %)

Bearish % = Long(B) % / (Long(A) % + Long(B) %)

where long/short% are defined in Q1.

The Sentiment Indicator aims to reflect the overall market sentiment, thus offering traders guidance on their trades. Typically, opening a position on the minority/contrarian side will receive funding fee payment.


---

# 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://derivio.gitbook.io/v1/trading/perpetual-futures/global-funding-rate.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.
