Trading on the bonding curve
A bonding curve calculates the token price from a formula. Before graduation, you trade against that curve rather than against another user's order.
Buying adds USDC and removes tokens from the curve. Selling returns tokens and removes USDC. Buys generally move the price up; sells move it down. A trade's average execution price differs from the price shown before the trade, particularly when the order is large.
The curve graduates when it holds 2,200 net USDC. Net means after trading fees. Sells reduce the amount raised, so progress can move backwards.
Buying and selling#
- Open a token from Explore.
- Choose Buy or Sell.
- Enter the amount and review the expected output, fee and minimum received.
- Approve the required asset spend if prompted.
- Sign the trade and complete transaction delivery.
Buys use USDC. Sells use tokens in your wallet. Both charge a 1% fee.
The app caps a final buy at the remaining curve capacity. Once the curve is fully funded, further curve buys are unavailable. If the token shows Complete bonding, graduation needs a separate transaction before trading moves to the pool.
How the curve calculates a quote#
The curve uses virtual reserves for pricing and tracks actual USDC separately. Virtual reserves do not represent money available for withdrawal.
In the formulas below:
Vis the fixed virtual USDC reserve of 2,200 USDC.Qis actual net USDC currently raised.Tis the current virtual token reserve.- All calculations use integer token amounts before decimal formatting.
For a buy with gross USDC input G, subject to the remaining capacity:
Net USDC = floor(G Γ 9,900 / 10,000)
Fee = G β Net USDC
Tokens received = floor(T Γ Net USDC / (V + Q + Net USDC))For a sale of X tokens:
Gross USDC = floor((V + Q) Γ X / (T + X))
Fee = ceil(Gross USDC Γ 100 / 10,000)
USDC received = Gross USDC β FeeThe contract rejects a sale that would redeem more USDC than the curve actually holds in its accounting. Previously paid fees are not part of that backing.
