Ray is the Solana LP Lifecycle From Deposit to Exit and Impermanent Loss
Ray is this page's shorthand for a Raydium liquidity-provider workflow on Solana: deposit a token pair, verify the resulting position, adjust its capital and withdraw both assets. CPMM positions return fungible LP tokens, while CLMM positions mint a range-bound NFT. As the pool price diverges from entry, the asset mix changes and impermanent loss emerges against simply holding.
The Ray workflow therefore needs two records: the on-chain position state and an entry snapshot. Together they show whether accrued fees offset divergence, whether a CLMM range remains active and what the final exit actually realized.
Choose CPMM or CLMM Before the First Deposit
The deciding factor for a Raydium deposit is management effort: choose CPMM for whole-curve liquidity or CLMM for a monitored price range.
A CPMM spreads liquidity across the full curve and asks for two assets at the pool ratio. Raydium auto-fills the second quantity from the first deposit amount. Signing mints fungible LP tokens representing a proportional claim on both vaults. Swap fees stay in the vaults and expand that claim, so no separate fee collection is needed. Removing part of the position burns the corresponding LP token amount and returns proportional reserves at the current ratio. This structure fits holdings whose owner accepts continuous rebalancing and prefers one balance to manage.
CLMM concentrates capital between two chosen boundaries and mints one position NFT. Liquidity earns swap fees only while the current tick sits inside those endpoints. Raydium lists four standard CLMM fee tiers - 0.01%, 0.05%, 0.25% and 1% - with tick spacings of 1, 10, 60 and 120 respectively. Each integer tick represents a 0.01% multiplicative price step, while spacing limits which ticks form valid boundaries. A narrower range raises capital density and demands closer monitoring; a wider range stays active across a broader move.
Price Divergence and the Exit Balance
Price divergence decides whether Ray's final token mix beats holding, because pool rebalancing continually sells the appreciating asset and buys the declining asset.
For a constant-product pool, divide LP value by hold value using 2 × √r ÷ (1 + r), where r is the exit-to-entry price ratio. A twofold relative price move produces 5.72% impermanent loss before fees, whether the ratio doubles or halves. A 1.5-fold move produces 2.02%, while a threefold move produces 13.40%. Accrued fees belong on the LP side of the comparison because they compensate part of this divergence gap.
In one hypothetical example, every changing input is hypothetical: 50 SOL, 5 000 USDC, an entry price of 100 USDC per SOL, an exit price of 200 and zero accumulated fees. Holding finishes at 15 000 USDC. A constant-product position holds about 35.36 SOL and 7 071 USDC after arbitrage aligns the pool with the doubled price, giving about 14 142 USDC. The 858 USDC gap equals 5.72% of the 15 000 USDC holding benchmark. These numbers isolate divergence; swap fees reduce the shortfall.
CLMM magnifies the same trade-off within its selected interval. When price reaches a boundary, the position becomes entirely one pool token, with the exact side set by quote orientation and movement direction. It then stops accruing swap fees until price re-enters the range. Moving the range converts the old exposure at current prices, realizes the divergence accumulated to that point and begins a new basis in another NFT position.
Deposit Preparation and Position Creation
A valid Raydium deposit starts with the correct pool, both required mints and enough SOL to settle every account-creation and signing instruction.
Phantom and Solflare expose the transaction instructions, while a connected Ledger signs through either wallet interface. Match both token mint addresses, the pool address and the requested program before approval. A Solana transaction carries a base fee of 5 000 lamports per signature and can request at most 1 400 000 compute units. Its optional priority fee equals the compute-unit price multiplied by the requested limit, divided by 1 000 000 and rounded upward. New token accounts and CLMM position state also require refundable rent deposits.
- Record the pool address and both mint addresses.
- Keep both deposit tokens available for an in-range position.
- Save the CPMM quote or both CLMM price boundaries.
- Note the expected LP amount or position NFT.
- Retain the transaction signature and pre-deposit balances.
Raydium creates missing token accounts, wraps SOL when needed and accounts for supported Token-2022 transfer-fee mints. A CPMM deposit places fungible LP tokens in the wallet unless they enter a farm. A CLMM deposit creates a PersonalPositionState plus an NFT mint whose supply is exactly 1. The SPL Token Program or Token-2022 records the ownership token. Deposit settlement is complete only when the transaction succeeds and the new balance appears under the intended wallet authority.
Reading the Position After Settlement
The authoritative Ray position is confirmed on-chain state: match its pool, balances, ownership record and CLMM range against the signed deposit quote.
For CPMM, the wallet's LP token amount represents a fraction of total LP supply, not a fixed quantity of SOL, USDC or RAY. The redeemable amounts move as swaps change the two reserves. For CLMM, PersonalPositionState records two tick endpoints, liquidity and fee-growth checkpoints for both pool mints. The position NFT identifies the owner. Current tick determines status: inside the range activates liquidity, while either outside region leaves the position in one token and pauses its fee-growth share.
Even so, Raydium's portfolio view provides the readable layer, while Solana Explorer and Solscan expose transaction status, account owners and token balance deltas. A CLMM pool supports up to three concurrent reward streams, each tracked separately from the two swap-fee balances. Those balances do not auto-compound. Compare the displayed lower tick, upper tick, current range status and wallet authority before treating an indexer's valuation as the completed position record.
Routine Range and Balance Adjustments
Routine Raydium maintenance changes capital only after the current range, token composition and unclaimed balances justify another signed position instruction on Solana.
IncreaseLiquidity adds assets to the same CLMM endpoints, so it preserves the range while changing its liquidity amount. The required ratio follows current price; near a boundary it leans toward one token and outside the interval it becomes single-sided. DecreaseLiquidity removes a selected fraction without destroying the position NFT. Both actions update fee-growth checkpoints, which separates amounts already owed from growth earned after the adjustment. Record each addition as a new lot because its entry composition differs from the original deposit.
A CLMM position has exactly two range endpoints, and neither endpoint is editable in place. Repositioning therefore means decreasing the old liquidity to zero, collecting pending fees and any of the pool's three reward streams, closing the old NFT and opening a new range. That sequence fixes the old position's token mix at the adjustment price. Reuse IncreaseLiquidity when the desired boundaries remain unchanged; create a replacement position when either boundary changes.
CPMM adjustments stay proportional: adding follows the current two-token reserve ratio and removing burns selected LP units. A separate swap changes the target wallet mix.
How Do You Close a Raydium Position Completely?
A complete Raydium exit removes all liquidity, collects every owed token balance and closes the position record only after those transfers settle successfully.
For CPMM, move LP tokens out of any Raydium farm first because staked units are not available to the withdrawal instruction. Choose the entire wallet LP balance, review both estimated outputs and sign the burn. The pool transfers the wallet's proportional share of its current reserves. Farm withdrawal settles its own pending rewards, while the liquidity withdrawal converts the LP claim into the two underlying tokens.
For CLMM, decrease liquidity to zero, collect both fee balances and every active reward, then close the position. ClosePosition burns its single NFT and closes PersonalPositionState, returning rent where applicable. Bundled instructions still expose each state change. An empty NFT with uncollected balances is not a finished exit.
After confirmation, verify the two underlying wallet balances, collected rewards, transaction status and disappearance of the closed CLMM record. Small rounding dust can remain after a CPMM withdrawal. A Token-2022 mint with an enabled transfer-fee extension delivers the net amount after its configured deduction. The exit total therefore comes from wallet balance changes, not the pre-signing estimate, whenever a mint-level transfer fee applies.
Maintenance Rules for the Next Cycle
Future Ray deposits improve when each closed position leaves a complete ledger of entry composition, active time, collected fees and final token amounts.
Keep the original quantities, their common quote value, every capital adjustment, collected fee amounts, rewards and Solana transaction costs. At exit, value the untouched entry quantities at the same timestamp and quote asset, such as USDC. Compare that holding benchmark with withdrawn tokens plus prior collections, then subtract execution costs. This separates impermanent loss from the pair's market return. For CLMM, also record time spent inside the range because only active liquidity earns its share. Open another range after its planned boundaries and maintenance cadence match the intended exposure.
Common questions about Ray
Does collecting CLMM fees change the active liquidity amount?
Collecting fees does not change a Raydium CLMM position's active liquidity amount. The action transfers accrued pool tokens to the wallet without changing the lower tick or upper tick. Fees do not auto-compound, so active liquidity grows only after a separate IncreaseLiquidity action redeposits tokens. The required token ratio follows current price inside the existing range.
Can I add only one token to a Raydium CLMM position?
A Raydium CLMM position accepts one token when current price is at or outside the corresponding range boundary. A position opened around current price requires both pool tokens in the ratio determined by its lower and upper ticks. Single-sided liquidity behaves like a range order: movement through the interval converts exposure while the position earns fees only when active.
Why does a Token-2022 withdrawal show a transfer-fee deduction?
A Token-2022 mint with an enabled transfer-fee extension deducts its configured fee when tokens move from the pool vault to the wallet. Raydium accounts for supported transfer-fee mints and displays the deduction before signing the withdrawal. Check both underlying token deltas separately in the final wallet settlement because either mint can define its own transfer-fee parameters.
Is a zero-liquidity CLMM NFT already closed?
A zero-liquidity CLMM NFT remains open on Solana until pending fees and rewards are collected and ClosePosition executes. Closing burns the Raydium position NFT, closes its PersonalPositionState account and returns account rent where applicable. If the NFT remains visible, confirm whether token fees, reward balances or the final close instruction still await settlement.
How long does a standard Raydium liquidity exit take?
An ordinary unlocked position has no protocol withdrawal delay. A CPMM exit completes when its signed withdrawal transaction confirms, while a CLMM exit requires decrease, collection and closure instructions that the interface may bundle. Network scheduling and priority-fee selection determine elapsed time. Burn & Earn positions are different because their liquidity was permanently locked by design.
Will increasing a CLMM position reset its fee accounting?
Increasing liquidity does not reset a Raydium CLMM position's fee accounting. IncreaseLiquidity updates fee-growth checkpoints, preserves amounts already owed and adds capital within the same two tick endpoints. It changes the economic basis because new tokens enter at the current ratio. Track the addition as a separate lot for an accurate impermanent-loss comparison at final withdrawal.