# Welcome

Granite is a Bitcoin Liquidity Protocol that provides the first truly non-custodial, secure, and decentralized way to borrow against Bitcoin.

The protocol allows borrowers to take stablecoin loans using Bitcoin as collateral, without exposure to counterparty or rehypothecation risk. Liquidity providers can earn yield on stablecoins by providing liquidity to the pool, which is then lent to borrowers.

Loans in Granite are best thought of as lines of credit, without set terms or repayment schedules. As long as the borrower maintains an adequate loan-to-value ratio (LTV), keeping their account in good health, they are not subject to liquidation. If a borrower’s LTV falls too low, a portion of their capital will be liquidated to bring their account back to solvency.

Granite enables BTC users to access DeFi without centralized custodians by leveraging Stacks’ soon-to-be-launched Nakamoto upgrade and [sBTC](http://sbtc.tech) Bitcoin bridge.&#x20;


# About Granite

Bitcoin often sits idle in wallets due to limited DeFi functionality. Traditional Bitcoin-based lending solutions, CeFi or DeFi, force users to either accept custody risk from centralized lenders or unacceptable security tradeoffs DeFi liquidity protocols:

* **Centralization**, either of the lender (e.g. Unchained) or the Bitcoin wrapper (e.g. wBTC)
* **Rehypothecation of collateral** creates liquidity risk for borrowers
* **Multi-asset borrowing** unwittingly turns borrowers into de facto lenders, and exposes all users to “cross-margin pool risk” of the riskiest borrowable asset
* **Liquidation practices** are catastrophic for borrowers, wiping them out in downturns

Granite solves these issues by leveraging [Stacks’ Bitcoin L2](/introduction/stacks-sbtc-usdcx-aeusdc/stacks) capabilities and [sBTC](/introduction/stacks-sbtc-usdcx-aeusdc/sbtc) to provide a truly decentralized, non-custodial lending solution native to the Bitcoin ecosystem. It enables:

* **Bitcoin Holders (Borrowers)**: to deposit their Bitcoin as collateral and borrow stablecoins, maintaining their BTC exposure while accessing liquidity
* **Liquidity Providers**: to supply stablecoins to the protocol in order to earn passive yield from borrower interest payments


# Key Benefits

Granite has mitigated the most significant risks associated with Cefi and DeFi lending/borrowing:

* **Decentralized:** Granite is a DeFi protocol built on the Stacks Bitcoin layer using the sBTC bridge to bring Bitcoin into DeFi, allowing users to avoid the centralization risk of CeFi lenders and custodial wrappers
* **Non-custodial:** Granite uses a non-custodial architecture, so you retain complete authority over your digital assets while lending and borrowing. All protocol interactions are controlled by transparent smart contracts that you directly interact with
* **No rehypothecation or “pooled-risk”:** Granite never lends out collateral and only has a single borrowable asset per market, eliminating liquidity risk for borrowers and the “cross-margin pool-risk” that exposes all users to the downside of the riskiest borrowable asset
* **Isolated Markets:** Granite’s markets each have a single borrowable stablecoin, preventing cross-contamination of risks between different assets
* **Soft liquidations:** Unlike other protocols that liquidate 50-100% of a position, liquidations on Granite only occur up to the point of restoring solvency. This protects borrowers from excessive collateral loss and is more favorable than traditional DeFi liquidation mechanisms.
* **Offline position tracking:** Granite supports configurable Telegram notifications to track debt ratios, interest rates, and account health metrics.&#x20;
* **Safety Module:** Granite provides an extra layer of security for liquidity providers against bad debt by allowing LPs to stake their position to be a junior tranche “first line of defense”.


# Stacks, sBTC, USDCx, aeUSDC


# Stacks

Granite is built on Stacks, a Bitcoin L2 that enables smart contract functionality while inheriting Bitcoin’s security. Applications in Stacks are written in Clarity, a smart contracting language specifically designed for high-stakes DeFi applications. Clarity prioritizes predictability and security through limited expressivity, which reduces the attack surface and prevents common smart contract vulnerabilities like re-entrancy attacks. It also includes post conditions and human-readable code on the blockchain, providing an additoinal layer of user protections.

Learn more about:

* [Stacks](https://stacks.co/)
* [Clarity](https://clarity-lang.org/)


# sBTC

The protocol uses sBTC to bridge Bitcoin into DeFi without swapping or exposure to centralized custodians. sBTC maintains a 1:1 peg with BTC through a decentralized bridge and leverages the unique proof-of-transfer (PoX) consensus mechanism of Stacks for enhanced security.

Learn more about:

* [sBTC](https://docs.stacks.co/concepts/sbtc)
* Stacks' [sBTC bridge](https://app.stacks.co/)


# USDCx

USDCx is a 1:1 USDC-backed stablecoin issued through Circle xReserve and native to Stacks.

Stacks now has a fully USDC-backed stablecoin that plugs directly into Circle’s multichain ecosystem and brings stable, interoperable dollar liquidity to Bitcoin’s leading Layer 2.

#### What is USDCx? <a href="#what-is-usdcx" id="what-is-usdcx"></a>

USDCx is a 1:1 USDC-backed stablecoin issued through Circle xReserve and native to Stacks. It will exist as a SIP-010 token on Stacks.

Circle's xReserve provides cryptographic attestations for deposits and minting, while Circle Gateway and CCTP handle cross-chain movement. The result is USDC on Stacks without third-party bridges, wrapped assets, or fragmented liquidity.

For more info on xReserve, check out the dedicated Circle docs [here](https://developers.circle.com/xreserve).

\
The USDCx Bridge app is maintained by Stacks Labs and is powered by Circle xReserve.

> Acquire USDCx through the [official bridge app](https://bridge.stacks.co/) or migrate your aeUSDC into USDCx to take advantage of better liquidity and improved trust assumptions.

Additionally, users can bridge to USDCx from a variety of cross-chain stablecoins by using the [Allbridge Core](https://core.allbridge.io/pools) stableswap protocol.&#x20;


# aeUSDC

aeUSDC is a legacy stablecoin issued by Allbridge. Prior to Circle's launch of USDCx, Allbridge created a wrapped USDC asset on Stacks. \
\
This asset will be deprecated by the Stacks Ecosystem in H1 2026. To continue accessing aeUSDC, please use the [Bitflow DEX](https://www.bitflow.finance/) to swap the asset.&#x20;


# Audits and Bug Bounties

Security is paramount at Granite. The protocol has undergone multiple comprehensive security audits:

* Security audit by [Clarity Alliance](https://github.com/GraniteProtocol/audits/blob/main/ClarityAlliance_October2024.pdf) (October 2024)
* Security audit by [Strata Labs](https://github.com/GraniteProtocol/audits/blob/main/StrataLabs_June2024.pdf) (June 2024)
* Security audit by [Halipot](https://github.com/GraniteProtocol/audits/blob/main/Halipot_July2024.pdf) (July 2024)
* Security audit by [ABA](https://github.com/GraniteProtocol/audits/blob/main/ABA_August2024.pdf) (August 2024)
* Safety Module audit by [ABA](https://github.com/GraniteProtocol/audits/blob/main/ABA_SafetyModule_September2024.pdf) (September 2024)
* Pyth Audit by [Clarity Alliance](https://github.com/GraniteProtocol/audits/blob/main/2025-02-06%20Granite%20Misc%20Upgrades%20Audit%20-%20Clarity%20Alliance.pdf) (February 2025)

All audit reports can be found in our [public audits repository](https://github.com/GraniteProtocol/audits).

\
Granite has a comprehensive Bug bounty program with [Immunefi](https://immunefi.com/bug-bounty/granite-protocol/information/) with rewards up to $100,000.


# Quick Links

* [Website](https://granite.world/)
* [App](https://app.granite.world/)
* [GitHub](https://github.com/GraniteProtocol)
* [Documentation](https://docs.granite.world/)


# Getting Started


# Wallet Setup

Before interacting with Granite Protocol, you’ll need to set up a compatible wallet and connect it to the application.

Granite Protocol currently supports the following wallets:

* [Leather Wallet](https://leather.io/)
* [Xverse Wallet](https://www.xverse.app/)
* [Fordefi Wallet](https://fordefi.com/) (Multisig)
* [Asigna](https://www.asigna.io/) (Multisig)

To get started:

1. Install a supported wallet as a browser extension from their official websites:

   * [Leather Wallet](https://leather.io/)
   * [Xverse Wallet](https://www.xverse.app/)

   <figure><img src="/files/rmUXm4QdwdyALYBpT0Fg" alt=""><figcaption></figcaption></figure>
2. Create a new wallet or import an existing one following your chosen wallet’s setup process

<figure><img src="/files/e6JT4QnO1lqV8vVUDBMk" alt="" width="375"><figcaption></figcaption></figure>

3. Ensure you have:

* STX tokens for transaction fees
* BTC if you plan to borrow
* Stablecoins if you plan to provide liquidity


# Connecting to Granite

Once you have a wallet set up, you can connect to Granite Protocol:

1. Visit [app.granite.world](https://app.granite.world/)
2. Click the “Connect Wallet” button in the top right corner

<figure><img src="/files/oNbBu44jnebhPE8SOMF8" alt=""><figcaption></figcaption></figure>

3. Select your preferred wallet from the connection modal

<figure><img src="/files/Ie7abJdriq2KBPtviiZv" alt="" width="375"><figcaption></figcaption></figure>

3. Your wallet will prompt you to approve the connection. Review the requested permissions and approve.

<figure><img src="/files/8mgeVBeZTfZL1PH7cYZO" alt="" width="375"><figcaption></figcaption></figure>

5. Once connected, you’ll see:

* Your wallet address in the top right
* The two different markets in the menu
* Your account overview, including any supplies or borrowings
* Access to all protocol features

<figure><img src="/files/dnR1XaDbRLtUdsiLQZy3" alt=""><figcaption></figcaption></figure>


# Assets

You may need the following assets to use Granite as a Borrower or Liquidity Provider.

* STX tokens for transaction fees
  * STX tokens are available on
    * CEXs: Binance, Coinbase, Kraken, OKX, Bybit, and other venues
      * See more at [CoinGecko Markets](https://www.coingecko.com/en/coins/stacks#markets)
    * DEXs: [Alex](https://app.alexlab.co/swap), [Bitflow](https://app.bitflow.finance/trade), [Velar](https://app.velar.com/swap)
    * In wallet onramps with Leather & Xverse
* BTC if you plan to borrow

  * To use Granite, you'll need to bridge BTC to sBTC using the sBTC Stacks [Bridge](https://app.stacks.co/).

  <figure><img src="/files/LDg3cXzDw2u47C4cn9CA" alt=""><figcaption></figcaption></figure>

  * Another option is in-wallet swaps with [Leather](https://leather.io/guides/bridge-sbtc).

  <figure><img src="/files/mweL7BUQoTRF5jzKDora" alt="" width="375"><figcaption></figcaption></figure>
* Stablecoins, if you plan to provide liquidity
  * Liquidity pools in Granite primarily use USDCx, a stablecoin issued by [Circle's Xreserve](https://www.circle.com/blog/usdcx-on-stacks-now-available-via-circle-xreserve) contract, issued on the Stacks Blockchain.&#x20;
    * You can also bridge USDCx from a variety of cross-chain stablecoins with [Allbridge's core stableswap pool.](https://core.allbridge.io/)
  * Granite has a legacy pool using asUSDC, a bridged USDC asset issued by Allbridge. We will close this market in 2026 to fully support USDCx markets. For users who need to access aeUSDC, please swap assets using the Bitflow Dex.&#x20;


# Getting USDCx

Most of Granite's markets will transition to USDCx, a 1:1 USDC-backed stablecoin issued through Circle xReserve and native to Stacks.

To get USDCx, you'll need:

* USDC on Ethereum mainnet (ERC-20)
* ETH for gas fees
* STX for gas fees

To get USDCx on Granite, go to the USDCx market menu.

<figure><img src="/files/gZ7vAW7zqjWw4IPoMxUH" alt="" width="221"><figcaption></figcaption></figure>

On the USDCx Wallet Balance, click the "Bridge" button.

<figure><img src="/files/wO0fWedJhqW4z78GvPXJ" alt=""><figcaption></figcaption></figure>

Once you've clicked on the Bridge, you'll be directed to the official USDCx bridge [link](https://bridge.stacks.co/usdc/eth/stx).&#x20;

From here, you can convert back and forth to USDCx and USDC.\ <br>

<figure><img src="/files/NoHzRiz92ySweN5YZLTA" alt=""><figcaption></figcaption></figure>


# Bridging aeUSDC

### aeUSDC Bridging

### \*aeUSDC will sunset in May 2026. To continue to access aeUSDC, please use the swap feature on Bitflow DEX.&#x20;

{% embed url="<https://youtu.be/HWH6SjgqIdE?feature=shared>" %}
Video guide how to bridge USDC to aeUSDC with Allbridge Classic
{% endembed %}

Go to [Allbridge Classic](https://app.allbridge.io/bridge?from=ETH\&to=STX\&asset=USDC) and connect the origin chain to the destination chain, Stacks.

<figure><img src="/files/dSxPEMaZh4E63bfr9qen" alt="" width="375"><figcaption></figcaption></figure>

Connect the origination chain wallet and click Confirm.

<figure><img src="/files/kXAXRamnwNSRjx90Pd37" alt="" width="305"><figcaption></figcaption></figure>

Designate the Stacks address and the amount of USDC token you wish to bridge.

<figure><img src="/files/NmIwYDw6ecM70mbsevqR" alt="" width="375"><figcaption></figcaption></figure>

Once you have confirmed the transactions, you must wait 80 confirmations.

<figure><img src="/files/b541on3oiHvhFqqRqbgg" alt="" width="375"><figcaption></figcaption></figure>

Upon completion, you can receive the newly minted aeUSDC.&#x20;

<figure><img src="/files/uXpiZgnz34jv6VDbnvsI" alt="" width="375"><figcaption></figcaption></figure>

Connect the designated Stacks wallet.

<figure><img src="/files/Jbd8RJAisbspnTpIFhSQ" alt="" width="307"><figcaption></figcaption></figure>

Click the Receive button to trigger the transaction signing.

<figure><img src="/files/AZPB7dLpA1wYmsdV2Oao" alt="" width="375"><figcaption></figcaption></figure>

Sign the Unlock transaction from your wallet pop-up and click Confirm.

<figure><img src="/files/n5RRimb8B6OfoXl24FjR" alt="" width="364"><figcaption></figcaption></figure>

The minted aeUSDC will be sent to your Stacks wallet.

<figure><img src="/files/spc02h3EmHd4qgFdZWpe" alt=""><figcaption></figcaption></figure>


# Network Selection

Granite Protocol operates on:

* Mainnet: Production network
* Testnet: For testing features

The network is automatically detected based on your wallet’s configuration. Make sure your wallet is connected to the desired network before interacting with the protocol.


# Security Tips

1. Always verify you’re on the official Granite website ([app.granite.world](http://app.granite.world))
2. Make sure to back up your wallet’s private keys or seed phrase
3. Never share your wallet’s private keys or seed phrase
4. Review all transaction details before signing
5. Lock your wallet when you’re done using the application

For technical support or questions, visit our [Telegram](https://t.me/GraniteBTC) or [Documentation](https://docs.granite.world/).


# Borrowing

Granite allows users to leverage or “collateralize” their BTC to borrow stablecoins. By supplying BTC to Granite, users can obtain over-collateralized loans.

The maximum borrowing limit is determined by the value of the supplied collateral and the parameters set by Granite Governance.


# How to Borrow

### **Depositing Collateral**

1. Connect your wallet
2. Click “Borrow USDCx” or “Deposit”
3. Enter the amount of sBTC you wish to deposit - note that you must first bridge BTC into Stacks via the [sBTC bridge](https://app.stacks.co/)
4. Confirm the transaction in your wallet

Your collateral remains securely locked in the protocol and is never lent out to other users.

### **Understanding Borrow Capacity**

Your Borrow Capacity is the maximum amount of stablecoins you can borrow based on your collateral. It is calculated based on:

* Maximum Loan-to-Value (LTV) ratio set by governance
* Total value of your deposited BTC collateral
  * This is represented as “Collateral Value” in your account overview

> Example: If you deposit $10,000 worth of BTC and the maximum LTV is 75%, your maximum borrowing capacity would be $7,500 in stablecoins.

Your Available to Borrow is the amount of stablecoins you can currently borrow. It is calculated based on:

* Your Borrow Capacity
* Your current Borrowed Amount
* Protocol liquidity

> Example 1: If your Borrow Capacity is $7,500 and you have a Borrowed Amount of $2,500, your Available to Borrow would be $5,000.

> Example 2: If your Borrow Capacity is $7,500 and you have a Borrowed Amount of $2,500 and there is only $3,000 free liquidity in the protocol, your Available to Borrow would be $3,000.

### **Borrowing**

After you have deposited collateral, you can borrow stablecoins.

1. Connect your wallet
2. Click “Borrow USDCx”
3. Enter the amount of USDCx you wish to borrow - the maximum amount will be indicated in the Borrow modal
4. Confirm the transaction in your wallet


# Managing Your Position

### **Adding/Removing Collateral**

If you have an active borrow, you can add collateral to increase your Borrow Capacity and reduce liquidation risk. If you have excess collateral, you can also choose to withdraw it.

When removing collateral with an active debt position, you must maintain the minimum collateral ratio (determined by the Max LTV). For this reason, you will not be able to withdraw the full amount of your collateral, or even an amount that puts you into the liquidation zone. The exact amount you can withdraw is displayed in the Withdrawal modal.

### **Adding Collateral:**

* Increases Borrow Capacity
* Improves position health
* Reduces liquidation risk

### **Removing Collateral:**

* Reduces Borrow Capacity
* Degrades position health
* Increases liquidation risk

### Loan Repayment

Loans in Granite do not have a fixed repayment schedule. You can repay any amount at any time, as long as you maintain a healthy position where your Collateral Value is greater than your Liquidation Point.

To repay your loan, click “Repay” in the Borrow section of your account overview. In the Repay modal, enter the amount you wish to repay and confirm the transaction in your wallet.


# Liquidations

### Liquidation Point / Avoiding Liquidations

Your account can be liquidated if your Collateral Value falls below your Liquidation Point. The Liquidation Point is calculated as your Borrowed Amount divided by the Account Liquidation Threshold. The Account Liquidation Threshold is the weighted Liquidation Threshold of all of your Collateral.

Your liquidation risk is displayed in the Dashboard in the “Liquidation Risk Bar”

* 100% = Liquidation Point
* Borrow Capacity point = the maximum amount that you can borrow, in relation to your Liquidation Point
* Your Position = the amount that you have borrowed, in relation to your Liquidation Point

If your Liquidation Risk Bar reaches 100%, you can be liquidated.

Liquidations typically occur when your Collateral Value drops due to fluctuations in the collateral (BTC) price. To avoid liquidations, maintain an adequate “collateral buffer” of Collateral Value > Liquidation Point, and take into account historical volatility and price fluctuations for your collateral asset.

The more that you borrow in relation to your collateral, the higher your liquidation risk (from market movements). To reduce risk of liquidation, you can lower your loan-to-value ratio (LTV) by either repaying your loan or adding more collateral.

Granite also offers push notifications to alert you when your account is at risk of liquidation. Learn more about [Position Monitoring & Alerts](/core-protocol-features/borrowing/position-monitoring-and-alerts).

### How Soft Liquidations Work

Unlike most liquidity protocols, Granite employs a “soft liquidation” mechanism. This means that when a liquidation is triggered, only the minimum amount needed to restore account solvency (Collateral Value / Liquidation Point) is liquidated. This protects borrowers from excessive collateral loss and is more favorable to borrowers than traditional liquidation mechanisms.

> Example:

* Collateral Value = $10,000
* Borrowed Amount = $6,000
* Liquidation LTV = 75%
* Liquidation Point = $8,000 ($6,000 / 75%)
* Liquidation Reward = 10% (the amount that the liquidators will receive as a reward for liquidating the position)

> If the Collateral Value drops to $7,950 (0.6% below the Liquidation Point):
>
> * **In a typical lending protocol:** the liquidators would be able to liquidate 50-100% of the position. This would be catastrophic and would wipe out the borrower.
> * **In Granite:** the liquidators can liquidate back to solvency, which would involve repaying $214 of the debt and receiving $235 of collateral as a reward. The borrower would still have $7,715 of collateral left (out of the pre-liquidation value of $7,950).


# Position Monitoring & Alerts

### Telegram Alerts

To set up account health / upcoming liquidation alerts:

1. Click on the “Settings” gear icon in the top right corner of the application
2. Click on “Enable Notifications”
3. Enter your Telegram handle
4. In Telegram, send the /start command to the @GraniteAlertsBot
5. Confirm your wallet address
6. Select the Account Health level that you would like to be alerted for

To see your current Account Health level, send the /account\_health command to the @GraniteAlertsBot.

Note:

* When your Account Health drops below 1.0, your account can be [liquidated](about:blank#liquidations).

### Interest Rate Alerts

To set up interest rate alerts:

1. Click on the “Settings” gear icon in the top right corner of the application
2. Click on “Enable Notifications”
3. Enter your Telegram handle
4. In Telegram, send the /start command to the @GraniteAlertsBot
5. Confirm your wallet address
6. Select the Interest Rate level that you would like to be alerted for


# Liquidity Provisioning

Granite allows Liquidity Providers (LPs) to supply stablecoins to the protocol in order to earn yield from borrower interest payments. Interest rates are variable and based on the utilization rate of the market (more on Interest Rates).


# How to Supply

{% embed url="<https://www.youtube.com/watch?feature=youtu.be&v=xHQ_pjoKwJ8>" %}

1. Connect your wallet

<figure><img src="/files/ovqDDXeiTfFsqavVwrlx" alt="" width="375"><figcaption></figcaption></figure>

2. Click “Earn aeUSDC”

<figure><img src="/files/IRdQWkGJMHDlwQeZlpS7" alt="" width="277"><figcaption></figcaption></figure>

3. Enter the amount of aeUSDC you wish to supply in the Supply modal

<figure><img src="/files/afHx3QjgYjubSj59sHnq" alt="" width="375"><figcaption></figcaption></figure>

4. Confirm the transaction in your wallet

<figure><img src="/files/B05WwTP7JfOCbd3ucA8F" alt="" width="371"><figcaption></figcaption></figure>

5. Your aeUSDC is pooled with that of other LPs and is borrowed by borrowers to generate yield.

<figure><img src="/files/Kgp6IzWcmvLMf8GQs1US" alt="" width="375"><figcaption></figcaption></figure>

You can supply additional liquidity to the market at any time by clicking “Earn aeUSDC” and entering the amount of additional aeUSDC you wish to supply.


# How to Withdraw

1. Connect your wallet

<figure><img src="/files/SKnoKeHxYAUEoHlrjfqL" alt=""><figcaption></figcaption></figure>

2. Click “Remove aeUSDC”

<figure><img src="/files/FjtC2MIMj4PwjimUy8ru" alt=""><figcaption></figcaption></figure>

3. Enter the amount of USDC you wish to remove in the Remove modal

<figure><img src="/files/GALPNZVTjq8iBozLXQig" alt="" width="375"><figcaption></figcaption></figure>

4. Confirm the transaction in your wallet

<figure><img src="/files/B35GKiR8e4993K67dZkF" alt="" width="369"><figcaption></figcaption></figure>

<figure><img src="/files/y3VgDqw86jyYodJzB6Xr" alt="" width="362"><figcaption></figcaption></figure>

### Available Liquidity

Withdrawals are constrained by the liquidity of the market and the Protocol Reserve. If the currently available liquidity isn’t high enough to process the withdrawal, users should wait until more liquidity becomes available. Liquidity can increase when lenders supply more of the desired asset or borrowers repay their loans. Learn more about Liquidity Constraints.

When liquidity is low, additional liquidity is incentivized via the interest rate model. Learn more about Interest Rates.

Current liquidity can be seen on the Market page as the difference between Total Earning and Total Borrowing.

<figure><img src="/files/xlhWTHieWHSn0ECI0nIe" alt=""><figcaption></figcaption></figure>


# Interest Rate Model

Interest rates are variable and set dynamically based on an interest rate curve and the utilization rate of the market.

The rate received by LPs is the borrowers’ interest rate minus the Protocol Reserve rate.


# Safety Module (LP Staking)

The Safety Module enhances the protocol’s resistance to bad debt events by incentivizing LPs to participate in risk management by staking their LP position. LP positions staked in the Safety Module are the first line of defense against bad debt and will be automatically slashed in the event of a bad debt event.

In exchange for bearing a greater portion of the bad debt risk, staked LPs earn additional yield. This creates a dual-tranche LP pool: staked LPs earn higher returns but take on more risk (junior tranche), while unstaked LPs earn lower returns with reduced risk (senior tranche). More details on lending risks can be found in the [Lending Risks](about:blank#lending-risks) section.

The Safety Module reduces risk for non-staking LPs and increases rewards for staking LPs.

Staking returns do not need to be claimed. They are automatically included in staker’s returns.

### How to Stake

1. Connect your wallet
2. Navigate to the “Stake” section
3. Click “Stake”
4. Enter the amount of aeUSDC you wish to stake in the Stake modal
5. Confirm the transaction in your wallet

LPs can choose to stake a portion of their position or their entire position. Additional yield will only be accrued on the staked portion. The blended rate is displayed in the Stake modal and the Stake section.

### How to Unstake

1. Connect your wallet
2. Navigate to the “Stake” section
3. Click “Cooldown to Unstake”
4. Set the optional Calendar Reminder or Telegram Notification in the “Cooldown to Unstake” modal
5. Confirm the transaction in your wallet

Unstaking involves a “Cooldown Period” during which the gTokens are no longer eligible for yield accrual. The Cooldown Period is set by governance and is displayed in the Unstake modal and the Stake section. Positions that are in the Cooldown Period and positions that have completed the cooldown period but have not been withdrawn will still be slashed in a bad debt event. For this reason, LPs should remove their position after the Cooldown Period has ended.


# Lending Risks

Despite Granite’s robust security measures and software development practices, there are still risks associated with lending that could result in funds being temporarily or permanently inaccessible.

### Market Utilization and Liquidity Constraints

As discussed in the [Interest Rates](about:blank#interest-rates) section, interest rates for borrowers are determined by the utilization rate of the market. When the utilization rate passes the kink, it increases quickly in order to incentive liquidity in the market - this liquidity comes from borrowers repaying loans or LPs depositing additional funds to lend. The kink is the optimal utilization rate for the market, the ideal ratio of borrowed assets to total supply to optimize for withdrawal liquidity and minimize interest rates.

Even with this mechanism, it’s possible that utilization rates may spike, causing a liquidity shortage where funds are not available in the protocol to process withdrawals. If this occurs, LPs may experience withdrawal constraints and would need to wait until more liquidity becomes available before being able to withdraw.

If this conditions persists, interest will accrue rapidly enough on borrower positions that they will be pushed into liquidation, freeing up funds for LP withdrawals.

### Bad Debt Exposure

Bad debt occurs when the collateral value of a position is insufficient to cover the borrower’s debt, resulting in a loss for the protocol.

Bad debt can be incurred in two ways:

* **Liquidation failure:** This can occur when an asset used as collateral lacks liquidity or when there are inefficiencies in the liquidation process.

  > To protect the protocol from this threat, Granite employs batch liquidations (allowing for the liquidation of multiple positions at once), a robust off-chain network of liquidators, and caps that limit borrowing based on the depth of liquidation DEX/CEX pools.
* **Oracle failure:** This occurs when the oracle network fails to update prices accurately during extreme market conditions or network congestion, resulting in improper liquidations based on inaccurate price data.

  > To protect the protocol from this threat, Granite employs Pyth price oracles. These oracles are highly regarded in the blockchain industry for their resilience and security.

In the unlikely occurrence of a bad debt event, losses from the bad debt will be socialized based on the [Loss Socialization Process](about:blank#loss-socialization-process).

### Loss Socialization Process

If a bad debt event occurs, the protocol will automatically socialize the losses in the following order:

1. Safety Module stakers
2. Protocol Reserve
3. Unstaked LPs

> **Example 1:**

* Safety Module stakers: $20,000
* Protocol Reserve: $50,000
* Unstaked LPs: $300,000

> If a bad debt event of $15,000 occurs, the Safety Module stakers will be slashed by $15,000, leaving $5,000 remaining. The Protocol Reserve and Unstaked LPs will not be slashed at all since the losses were covered by the Safety Module stakers.

> **Example 2:**

* Safety Module stakers: $20,000
* Protocol Reserve: $50,000
* Unstaked LPs: $300,000

> If a bad debt event of $75,000 occurs, the Safety Module stakers will be slashed by $20,000 (fully), the Protocol Reserve will be slashed by $50,000 (fully), and the Unstaked LPs will be slashed by $5,000.

Note that staked LPs (in the Safety Module) who are in cooldown but have not yet withdrawn will still have their position slashed immediately upon a bad debt event.


# Isolated Markets

Granite’s isolated market model is designed to address the inherent risks associated with pooled-risk models in DeFi. By implementing isolated markets, Granite ensures that each market operates independently, thereby reducing systemic risk and providing a safer environment for users. Learn more about [Pooled Risk](https://granite.world/blog/pooled-risk).


# Single Asset Pools

In Granite’s isolated market model, each market supports a single borrowable asset. This approach creates a clear and predictable risk profile, eliminating the interdependency between assets that can lead to cascading failures in pooled-risk protocols. By supporting single asset pools, Granite ensures that users are not exposed to the volatility and unpredictability of mixed asset pools inherent in most DeFi lending protocols.


# Benefits

The isolated market model offers several key benefits:

1. No Rehypothecation: When users deposit collateral, it remains theirs. Granite never lends it out to other users, ensuring that assets are always available when needed. This eliminates the liquidity risk that borrowers face in traditional DeFi models where their collateral might be lent out without their knowledge.
2. Independent Liquidity: Each isolated market does not share liquidity with others, allowing for tailored risk profiles. This independence enables more precise risk management and increased flexibility in market parameters.
3. Customizable Parameters: Each market has its own set of risk parameters, including its own Max and Liquidation LTVs, Interest Rate Model, and Oracle. This customization allows Granite to provide a more secure and user-friendly experience.


# No Rehypothecation

Core to Granite’s design is a commitment to security by not engaging in rehypothecation, a practice common in many DeFi platforms where borrowers’ collateral is lent out to generate additional yield. While rehypothecation can increase returns, it introduces significant liquidity risks for both borrowers and LPs.

By avoiding rehypothecation, Granite ensures that users’ collateral remains fully reserved and readily available at all times, providing a higher level of predictability and transparency. This approach minimizes the risks associated with lending, offering borrowers peace of mind that their assets are not exposed to unforeseen risks or complications.

Because Granite doesn’t rehypothecate collateral, it’s always available for withdrawal after loan repayment.


# Interest Rates

Interest rates on Granite are variable and set dynamically based on an interest rate curve and the utilization rate of the market. Interest accrues continuously but is only charged upon position repayment.

There are no origination fees or hidden fees on Granite. All fees and rates are transparently displayed in the interface.

The rate received by LPs is the borrowers’ interest rate minus the Protocol Reserve rate. LP yield is split between staked and unstaked LPs depending on the staking rate in the Safety Module.

The current interest rate curve is displayed in the Markets section.


# Utilization Rate

The Utilization Rate is the ratio of borrowed assets to the total supply of the asset.

> Example: If there is $50,000 in borrowed USDC and $100,000 in total supply, the Utilization Rate is 50%.


# Rate Calculation

The interest rate curve defines the interest rate for different utilization rates. The curve parameters are set by governance and can be changed over time. Typical curve parameters will involve a base rate, a primary slope, a kink, and a post-kink slope.

<figure><img src="/files/ifKEYchTSWFyWWEZl9Nl" alt=""><figcaption><p>Sample Interest Rate Curve. x axis = utilization; y axis = interest rate</p></figcaption></figure>


# Market Dynamics

When the utilization rate is low, interest rates are lower to incentivize borrowers to borrow more assets. When the utilization rate are higher, interest rates increase to incentivize lenders to supply more liquidity. When the utilization rates passes the kink, the interest rate increases at a much faster rate - this incentivizes lenders to supply more liquidity and borrowers to repay their loans.

<figure><img src="/files/vvuYkaUhbgtgDZGMYMPJ" alt=""><figcaption></figcaption></figure>

* 10% Utilization Rate = 4.5% Interest Rate
* 50% Utilization Rate = 7% Interest Rate
* 80% Utilization Rate (kink) = 8% Interest Rate
* 90% Utilization Rate = 15% Interest Rate <- *notice how the interest rate increases at a much faster rate when the utilization rate passes the kink*


# Safety Mechanisms


# Risk Parameters

Each market has its own set of parameters that determine the risk profile of the market. These parameters include:

* Max LTV
* Liquidation LTV
* Deposit Cap
* Interest Rate Model
* Safety Module
* Oracle


# Protocol Reserve

The Protocol Reserve is an asset pool that accrues value from borrower interest payments, as determined by the reserveRate set by governance. Each market has its own reserve.

The Reserve has several functions:

1. As the second line of defense against bad debt events after the Safety Module has been slashed
2. To provide additional withdrawal liquidity to LPs in low-liquidity situations
3. As general funds for governance to use as needed

The Protocol Reserve is displayed in the Markets section.


# Safety Module

The Safety Module enhances the protocol’s resistance to bad debt events by incentivizing LPs to participate in risk management by staking their LP tokens. Learn more about the Safety Module.


# Withdrawal Caps

Withdrawal caps are **protocol-level limits** on the amount of an asset that can leave Granite over a defined rolling time window. This protects users by limiting potential damage from an exploit, as attackers are prevented from draining an asset since they can only access a subset of protocol capital in a given time period.

Withdrawal caps apply to all ways that an asset can leave the protocol, including:

* Debt Cap: the amount of an asset that can be borrowed&#x20;
* Collateral Withdrawal Cap: the amount of collateral that can leave the system (this does not affect liquidations)
* Liquidity Provider (LP) Cap: how much liquidity providers can remove

If hit, withdrawal caps will linearly refill over the next 24 hours. They can also be refilled by depositing more of an asset.

Withdrawals at or near the cap are monitored actively by [protocol guardians](/protocol-information/guardians), who can then pause the protocol if suspicious behavior is detected.

Caps are manged by [protocol governance](/protocol-information/governance).

\
**Example:**

* Cap is set to 10% for BTC collateral, and there is $10M of BTC collateral in the protocol
* An individual user with a $100K deposit withdraws $100K - nothing happens, as the protocol-level cap has not been hit
* $900K of BTC collateral is then withdrawn  - the cap is hit (10% of $10M), and guardians are notified to review the withdrawal behavior for any suspicious activities
* The next attempted withdrawal of BTC collateral will fail since the cap has been hit
* Withdrawal capacity will increase linearly over the next 24 hours, back to the new capacity of $900K (10% of the remaining $9M).
  * By waiting for 20 minutes, the next borrower can withdraw their $1000 of BTC collateral since the cap has partially refilled.
* If somebody then deposits another $1M, the cap is refilled by the deposit.


# Oracle Implementation

Granite uses the Pyth price oracle to provide price feeds for each market. Pyth is a highly regarded oracle network that supplies price feeds for 540 assets on 80+ blockchains. Granite chose Pyth because it is known for its resilience and security. Learn more about [Pyth](https://pyth.network/).


# Withdrawal Caps

Granite maintains strict withdrawal caps to protect users in the event of any security threats. Our withdrawal caps are listed on the [market page](https://app.granite.world/market) for each asset market.&#x20;

**USDCx**

<figure><img src="/files/qytgjH1nP0K4zHDG4yY8" alt=""><figcaption></figcaption></figure>

\
**aeUSDC**

<figure><img src="/files/nXjF46Ww1TTP4LWmNAsa" alt=""><figcaption></figcaption></figure>


# Market Risk Parameters


# Interest Rate Curves


# Audits & Bug Bounty

Security is paramount at Granite. The protocol has undergone multiple comprehensive security audits:

* Full protocol audit by Strata Labs (June 2024)
* Full protocol audit by Halipot (July 2024)
* Full protocol audit by ABA (August 2024)
* Safety Module audit by ABA (September 2024)
* Full protocol audit by Clarity Alliance (October 2024)
* Upgrades audit by Clarity Alliance (February 2025)
* Liquidations Audit by Cyba Blockchain Security (June 2026)

All audit reports can be found in our [public audits repository](https://github.com/GraniteProtocol/audits).

Granite has a comprehensive Bug bounty program with [Immunefi](https://immunefi.com/bug-bounty/granite-protocol/information/), with rewards up to $100,000.


# Contracts

**USDCx Deployed Contracts:**

* state-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.state-v1?chain=mainnet>
* linear-kinked-ir-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.linear-kinked-ir-v1?chain=mainnet>
* pyth-adapter-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.pyth-adapter-v1?chain=mainnet>
* staking-reward-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.staking-reward-v1?chain=mainnet>&#x20;
* staking-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.staking-v1?chain=mainnet>
* withdrawal-caps-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.withdrawal-caps-v1?chain=mainnet>
* borrower-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.borrower-v1?chain=mainnet>
* meta-governance-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.meta-governance-v1?chain=mainnet>
* governance-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.governance-v1?chain=mainnet>
* liquidator-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.liquidator-v1?chain=mainnet>
* liquidity-provider-v1:\
  <https://explorer.hiro.so/txid/SP3M2BYF7RGF8WKW5FVDNJ6WR8D7AR9BHDXAKPXZE.liquidity-provider-v1?chain=mainnet>\
  \
  **aeUSDC Deployed Contracts:**
* constants-v1.clar: <https://explorer.hiro.so/txid/SP35E2BBMDT2Y1HB0NTK139YBGYV3PAPK3WA8BRNA.constants-v1?chain=mainnet>
* constants-v2.clar: [https://explorer.hiro.so/txid/SP3BJR4P3W2Y9G22HA595Z59VHBC9EQYRFWSKG743.constants-v1?chain=mainnet](https://explorer.hiro.so/txid/SP3BJR4P3W2Y9G22HA595Z59VHBC9EQYRFWSKG743.constants-v2?chain=mainnet)
* borrower-v1.clar: <https://explorer.hiro.so/txid/SP26NGV9AFZBX7XBDBS2C7EC7FCPSAV9PKREQNMVS.borrower-v1?chain=mainnet>
* staking-v1.clar: <https://explorer.hiro.so/txid/SP3BJR4P3W2Y9G22HA595Z59VHBC9EQYRFWSKG743.staking-v1?chain=mainnet>
* withdrawal-caps-v1.clar: <https://explorer.hiro.so/txid/SP26NGV9AFZBX7XBDBS2C7EC7FCPSAV9PKREQNMVS.withdrawal-caps-v1?chain=mainnet>
* flash-loan-v1.clar: <https://explorer.hiro.so/txid/SP26NGV9AFZBX7XBDBS2C7EC7FCPSAV9PKREQNMVS.flash-loan-v1?chain=mainnet>
* governance-v1.clar: <https://explorer.hiro.so/txid/SP26NGV9AFZBX7XBDBS2C7EC7FCPSAV9PKREQNMVS.governance-v1?chain=mainnet>
* liquidator-v1.clar: <https://explorer.hiro.so/txid/SP26NGV9AFZBX7XBDBS2C7EC7FCPSAV9PKREQNMVS.liquidator-v1?chain=mainnet>
* liquidity-provider-v1.clar: <https://explorer.hiro.so/txid/SP26NGV9AFZBX7XBDBS2C7EC7FCPSAV9PKREQNMVS.liquidity-provider-v1?chain=mainnet>
* meta-governance-v1.clar: <https://explorer.hiro.so/txid/SP35E2BBMDT2Y1HB0NTK139YBGYV3PAPK3WA8BRNA.meta-governance-v1?chain=mainnet>
* state-v1.clar: <https://explorer.hiro.so/txid/SP35E2BBMDT2Y1HB0NTK139YBGYV3PAPK3WA8BRNA.state-v1?chain=mainnet>
* linear-kinked-ir-v1.clar: <https://explorer.hiro.so/txid/SP35E2BBMDT2Y1HB0NTK139YBGYV3PAPK3WA8BRNA.linear-kinked-ir-v1?chain=mainnet>
* pyth-adapter-v1.clar: <https://explorer.hiro.so/txid/SP26NGV9AFZBX7XBDBS2C7EC7FCPSAV9PKREQNMVS.pyth-adapter-v1?chain=mainnet>


# Governance

Governance is managed by a multisig requiring a 60% signer threshold.

Some governance actions have a timelock: a period of time after the approval of a governance proposal during which the proposal cannot be executed, giving users a buffer period to review the governance proposal and react accordingly. Actions that update governance or protocol variables are time locked so that users may withdraw funds before the action is executed, if desired. The timelock period is set to 24 hours.

Governance can perform the following actions:

<table><thead><tr><th width="244.77734375">Action</th><th width="390.9140625">Description</th><th>Timelock</th></tr></thead><tbody><tr><td>update-governance</td><td>Update governance contract used by the State Contract</td><td>Time locked</td></tr><tr><td>freeze-upgrades</td><td>Freeze contract upgrades - enabling this means that no contracts can be upgraded, the protocol is fully immutable</td><td>Time locked</td></tr><tr><td>set-deposit-asset-flag</td><td>Disable/enable depositing market assets by the LPs</td><td>N/A</td></tr><tr><td>set-withdraw-asset-flag</td><td>Disable/enable withdrawing market assets by the LPs<br><br>Used to selectively restart market functions (if necessary) after a pause</td><td>N/A</td></tr><tr><td>set-add-collateral-flag</td><td>Action to disable adding collateral to market by the borrowers<br><br>Used to selectively restart market functions (if necessary) after a pause</td><td>N/A</td></tr><tr><td>set-remove-collateral-flag</td><td>Action to disable/enable removing collateral from market. by the borrowers<br><br>Used to selectively restart market functions (if necessary) after a pause</td><td>N/A</td></tr><tr><td>set-borrow-flag</td><td>Action to disable/enable Borrow</td><td>N/A</td></tr><tr><td>set-repay-flag</td><td>Action to disable/enable Repay</td><td>N/A</td></tr><tr><td>set-liquidation-flag</td><td>Action to disable/enable Liquidation</td><td>N/A</td></tr><tr><td>pause-market</td><td>Action to pause market</td><td>N/A</td></tr><tr><td>unpause-market</td><td>Action to unpause market</td><td>N/A</td></tr><tr><td>update-collateral-settings</td><td>Action to update collateral settings or add new collateral to market.<br><br>Collateral setting include max-ltv, liquidation-ltv, liquidation-premium</td><td>Time locked</td></tr><tr><td>deposit-to-reserve</td><td>Action to deposit funds from Governance contract into Market reserve balance in the State contract</td><td>N/A</td></tr><tr><td>withdraw-from-reserve</td><td>Action to withdraw from Market reserve balance in the State contract. Withdrawal would withdraw into the governance contract; would be used in conjunction with <code>transfer-funds</code>.</td><td>Time locked</td></tr><tr><td>set-allowed-contract</td><td>Action to update Allowed contract list</td><td>Time locked</td></tr><tr><td>remove-allowed-contract</td><td>Action to remove allowed contract list</td><td>Time locked</td></tr><tr><td>add-guardians</td><td>Action to add guardians</td><td>Time locked</td></tr><tr><td>remove-guardians</td><td>Action to remove guardians</td><td>N/A</td></tr><tr><td>update-interest-rate-params</td><td>Action to update interest rate params</td><td>Time locked</td></tr><tr><td>update-protocol-reserve-percentage</td><td>Action to update protocol reserve percentage</td><td>Time locked</td></tr><tr><td>update-asset-cap</td><td>Action to update asset cap on market</td><td>N/A</td></tr><tr><td>transfer-funds</td><td>Action transfer funds from the governance contract to a specific recipient; would be used in conjunction with <code>withdraw-from-reserve</code>.</td><td>N/A</td></tr><tr><td>remove-collateral</td><td>Action to remove collateral from protocol. Removing a collateral means borrowers cannot interact with the collateral and liquidations would be stopped, and collateral value would not be counted in position value.<br><br>This would be used after a <code>pause()</code> if there is an oracle price attack, to protect against invalid withdraws or deposits<br><br>Can re-enable using <code>update-collateral</code> later</td><td>Time locked</td></tr><tr><td>set-interest-accrual-flag</td><td>Action to enable/disable interest accrual</td><td>N/A</td></tr><tr><td>update-reward-rate-params</td><td>Action to update staking reward rate params</td><td>Time locked</td></tr><tr><td>update-withdrawal-finalization-period</td><td>Action to update withdrawal finalization period</td><td>Time locked</td></tr><tr><td>update-pyth-token-feed</td><td>Action to update pyth token feed</td><td>N/A</td></tr><tr><td>reconcile-staking-lp-balance</td><td>Action to reconcile staking lp balance<br><br>In case somebody transfers lp tokens to the staking contract without actually staking them - this would stake these LP tokens as a donation to the current stakers</td><td>N/A</td></tr><tr><td>set-staking flag</td><td>Action to enable or disable staking</td><td>N/A</td></tr><tr><td>update-pyth-time-delta</td><td>Action to update pyth time delta</td><td>N/A</td></tr><tr><td>set-lp-cap</td><td>Action to set lp cap</td><td>Time locked</td></tr><tr><td>set-debt-cap</td><td>Action to set debt cap</td><td>Time locked</td></tr><tr><td>set-collateral-cap</td><td>Action to set collateral cap</td><td>Time locked</td></tr><tr><td>set-cap-time-window</td><td>Action to set withdrawal caps time window</td><td>Time locked</td></tr></tbody></table>


# Guardians

Guardians are wallets that have the ability to pause the protocol. Guardians monitor protocol state and initiate a pause if they detect potential exploits, allowing the protocol to minimize damage.

Following a pause, the protocol must be unpaused by governance.


# FAQs


# Community Resources


# Support Channels

* Telegram: <https://t.me/GraniteProtocol>
* Twitter: <https://twitter.com/GraniteBTC>


