Gearbox Protocol
  • Overview
  • Link Tree & Dev Docs
  • What can you do with leverage 2.0?
  • Protocol overview
    • How it works
    • Credit Accounts
      • AllowedList: Integrations
        • OLD: V1 and V2
      • How to add new Contracts & Assets to AllowedList
    • Liquidations
      • Reserve Fund
    • Protocol Fees
    • Tech Paper
    • FAQ
    • History: DAO-First Launch
      • Birth at ETHGlobal MarketMake 2021
      • Kovan testing with DegenScore & lobsterdao
      • Credit Account Mining
      • Early Testers and Discord
  • Traders & farmers
    • Opening a Credit Account
    • Margin Trading: PURE
      • Boosted Long/Short or "Free Leverage"
    • Leverage Points & Restaking
    • Leverage Farming
      • One-Click Strategies
      • Leveraged liquid staking
      • Leveraged stablecoin farming
      • Leveraged Curve V2 and Convex
      • Leveraged vanilla yVaults
      • Arbitrage of correlated assets
    • Tips for leverage users
      • How to avoid liquidations
      • How to close a Credit Account
    • PRO: Leverage Bible
  • Passive Lending
    • Pools & APY
      • OLD: V1-V2 Pools
    • Dashboard: How to Earn
  • GOVERNANCE | DAO
    • Main DAO Governance
      • Guards [Multisigs]
      • Community Delegates
    • Quotas and Gauges
      • Dashboard: Gauge Voting
  • GEAR Token
    • Supply Information
    • Utility & Staking
    • Legal Disclaimer
  • Security & Risks
    • Audits & Bug Bounty
    • Risks and T&C
Powered by GitBook
On this page
  • What is a Health Factor?
  • Total Value
  • Threshold Weighted Value
  • Liquidation Threshold

Was this helpful?

  1. Protocol overview

Liquidations

Defining liquidations, health factor, and weighted thresholds.

PreviousHow to add new Contracts & Assets to AllowedListNextReserve Fund

Last updated 1 year ago

Was this helpful?

How does the protocol ensure over-collaterization while allowing users leveraged operations?

When doing leverage with Gearbox, your becomes the collateral for external protocols/actions: both your initial funds and the borrowed amount you got from the protocol. Gearbox Protocol sees which tokens your portfolio consists of and can determine its value at all times, which are always calculated in the underlying borrowed asset which you opened that Credit Account in.

Gearbox uses a risk model to continuously assess the quality-value of a Credit Account. For each Credit Account, it computes its health factor.

Anyone can check the health factor and liquidate positions with a health factor less than 1.

As a user with a leverage position, you need to watch out for your health factor. Having it just above 1 puts you in risk of getting liquidated. Learn how to avoid liquidations.

Learn about the current fee model a user pays in case of a liquidation:

What is a Health Factor?

Hf(t)=TWV(t)b(t)+interest  accrued(t),H_{f}(t) =\frac{TWV(t)}{b(t) +interest\;accrued(t)}, Hf​(t)=b(t)+interestaccrued(t)TWV(t)​,

where b(t) is borrowed amount.

Let's dive into some math formulas to clarify how computation of the health factor works.

Total Value

Represents the Credit Account's balance in the underlying asset.

TV(t)=∑  ci(t)∗pi(t),TV(t)=\sum{\;c_i(t)*p_i(t)},TV(t)=∑ci​(t)∗pi​(t),

where c_i - balance of i-th asset in credit account, p_i - price of i-th asset calculated in underlying asset(from oracle).

Threshold Weighted Value

TWV(t)=∑min(Qi(t),  ci(t)∗pi(t)∗LTi)TWV(t)=\sum{min(Q_i(t),\;c_i(t)*p_i(t)*LT_i) } TWV(t)=∑min(Qi​(t),ci​(t)∗pi​(t)∗LTi​)

where: Q_i - Quota amount for i-th asset in Credit Account (see Quotas and Gaugessection),

Liquidation Threshold

Liquidation thresholds represents maximum allowable ratio of Loan-To-Value for the i-th asset (LTV is reciprocal of over-collaterization ratio of i-th asset). LT_i for underlying asset is constant and equals:

LTU=100%−Liquidation  Premium−Liquidation  FeeLT_U =100\% - Liquidation\;Premium -Liquidation\;FeeLTU​=100%−LiquidationPremium−LiquidationFee

How is Liquidation Threshold defined?

Gearbox Protocol uses statistics of 5-min, 15-min, 1h change of i-th asset's price (price is in the underlying asset) for the last 180 days.

Health Factor is a numeric representation of your account health. If your health factor drops below 1 or close to it, you might be liquidated. The higher the number is, the safer you are. There are some tips on how you can avoid liquidations, .

c_i - balance of i-th asset in credit account, p_i - price of i-th asset calculated in underlying asset(from oracle), LT_i - liquidation threshold, the credit account manager constant showing the maximum allowable ratio of for the i-th asset.

Anybody can run a liquidator bot and secure the protocol. You can chat about setting up your bot and other liquidator-things in .

How to avoid liquidations
Protocol Fees
check them here
Loan-To-Value
Discord
Credit Account