How do I see what my LP tokens are worth in a V2 pair?
To see what your LP tokens are worth, divide your balance by total supply, apply that share to both reserves, then price each token amount for position value.
The Finality Desk4 min read#a6e402

For a V2-style pair, your LP tokens represent a pro-rata claim on both current reserves, so their value is the value of your share of each token.
The calculation gives you the amounts of token0 and token1 the position would return now. The dollar value comes from pricing those two amounts at their current prices and adding them together.
V2-style pairs expose the reserves and supply needed for this calculation. A shiba swap pair is a concrete example: its pair contract provides those values through getReserves and totalSupply.
What do I need to calculate my LP position?
To calculate a V2-style LP position, you need the pair contract address and the wallet address holding the LP tokens.
Have the farm’s pool ID, or pid, ready as well if the LP tokens are staked. The pair address identifies the contract whose reserves back the position. The wallet address identifies the LP balance when the tokens are held directly.
How do I calculate what my LP tokens are worth?
Read the LP amount, total supply and reserves, then apply your share to each reserve and price the resulting token amounts.
Open the pair contract on Etherscan and select its Read Contract tab. For LP tokens held in your wallet, read balanceOf(your address). This is the amount of the pair’s LP token owned by that wallet.
For LP tokens staked in a farm, use the farm contract’s userInfo(pid, address) and take its amount value as the staked LP amount. The pair’s balanceOf(your address) can show zero in this case because the farm contract holds the LP tokens. Use the user’s recorded stake, not the wallet’s pair-token balance.
Read totalSupply and getReserves on the pair contract. The first is the total LP-token supply; the second returns the pool’s token reserves. Keep the reserve order matched to the pair’s token0 and token1.
Divide your LP amount by totalSupply to get your share of the pair. Multiply that share by each reserve: token0 amount = (LP amount ÷ totalSupply) × reserve0; token1 amount = (LP amount ÷ totalSupply) × reserve1. Reserves are in raw units, so divide each result by 10 raised to that token’s decimals to express it in token units.
Multiply each token amount by that token’s current price in the same quote currency, then add the two values. Preserve enough precision during the calculation: rounding the share or token amounts too early can make the result differ slightly from a withdrawal amount. The resulting value changes when the reserves or token prices change.
Compare both token amounts with the withdrawal preview for the position on shiba swap. A match confirms that you used the right pair, LP amount and reserves; a small difference can come from rounding.
What does the calculation tell me?
The reserve-based result is the pair’s current pro-rata redemption amount, expressed as two tokens. It reflects the pool’s present reserve ratio, which can differ from the ratio at which you added liquidity.
The combined value is a snapshot. A swap can change the reserves and therefore your token amounts, while changes in either token’s market price change the quoted value. The calculation values the position now; it does not predict a later withdrawal value.
What might I ask next?
How do I compare this value with simply holding the two tokens?
Compare the position’s current value with the value of the two token amounts you originally contributed, priced at the same current prices. For a like-for-like comparison, include any fees or rewards you have received separately and account for any additional liquidity added or removed.
How do I withdraw the position back into both tokens?
Withdraw or remove liquidity through the pool’s withdrawal flow. A V2-style pair returns both tokens in proportion to the LP share being redeemed, based on the reserves at that time. The amounts can differ from today’s calculation if the reserves change before withdrawal.