Uniswap Swap Gas Cost What Affects the Fee and V2 vs V3 Differences
A Uniswap swap costs between 100,000 and 300,000+ gas on Ethereum mainnet. That range is wide because several factors stack on top of each other, and understanding what drives the number helps you estimate costs before you sign.
V2 vs V3 gas differences
Uniswap V2 uses a constant product formula. Every swap moves along a single curve, the math is simple, and the EVM executes it in fewer steps.
Uniswap V3 introduces concentrated liquidity. Liquidity providers can allocate funds within specific price ranges. When the swap price crosses from one tick to another, the contract must update active liquidity positions, and each tick crossing costs extra gas. A swap that crosses many ticks - say during high volatility or a large order - pays for those boundary updates.
The result: a straightforward V2 swap might use 100,000 - 150,000 gas. A comparable V3 swap that crosses ticks can run 180,000 - 300,000+ gas. The difference is not fixed; it depends entirely on how many ticks the trade crosses.
Multihop swaps add gas per hop
Uniswap lets you swap token A to token C via token B as an intermediate. Each hop is a separate swap contract call, and each call adds its own gas cost. A direct pair swap might use 150,000 gas, while adding a second hop roughly doubles the swap component. The overhead from the router contract also increases. Multihop routes are common when no direct pair exists or when the direct pair has poor liquidity.
ETH-to-Token vs Token-to-Token
Swapping ETH for a token uses a different contract path than token-for-token. ETH-to-token trades send ETH as the native currency, and the contract wraps it to WETH internally. Token-to-token trades involve two ERC-20 transfers plus the swap logic. The gas difference is small but real. ETH-to-token often uses slightly less gas because the inbound value is native ETH, not an ERC-20 that requires a transferFrom call. Token-to-token must pull the source token from your wallet, then push the destination token back, which adds about 10,000 - 20,000 gas.
Pool fee tiers affect routing
Uniswap V3 has multiple fee tiers per pair: 0.01%, 0.05%, 0.30%, and 1.00%. The router selects which tier to use based on the swap parameters and liquidity depth. A 0.01% pool often has lower liquidity concentrated in narrow ranges, so the swap may cross more ticks to fill the order, increasing gas. A 0.30% pool with deeper, wider liquidity may need fewer tick crossings. The fee percentage does not directly change gas; the liquidity distribution within that tier does.
L1 vs L2 gas costs
The gas figures above apply to Ethereum mainnet. The same swap on Arbitrum, Optimism, or Base costs far less in ETH terms.
On Arbitrum, a Uniswap V3 swap might use 100,000 - 200,000 gas as well. But the gas price on Arbitrum is typically a fraction of Ethereum's. The L2 sequencer fee is low, and the L1 security fee adds a small amount for posting the batch. Total cost in USD can be 90-95% lower than mainnet.
Optimism and Base work similarly. Base uses the same OP Stack as Optimism. Gas prices on Base have been lower than Optimism historically, though both vary, and the actual fee depends on the L2 gas price at the time of the transaction. The swap logic itself is the same; Uniswap deploys the same V3 contracts on these L2s. The gas units are comparable, while the price per gas unit is what changes.
Mental model for estimating gas before signing
You cannot know the exact gas cost before the transaction executes. But you can estimate.
Start with the base: a direct token-to-token swap on V2 costs roughly 120,000 gas. For V3, assume 150,000 gas as a floor, then add 20,000 gas per tick crossing you expect. A large swap or a volatile pair might cross dozens of ticks. Add 80,000 - 120,000 gas per additional hop, and add 10,000 - 20,000 gas for token-to-token versus ETH-to-token.
Wallet interfaces show estimated gas before you confirm. Compare that estimate to the numbers above. If the estimate says 400,000 gas for a simple swap, the route likely involves multiple hops or crosses many ticks, and you can switch to a direct pair or a lower-fee tier if one exists.
On L2s, the same logic applies. The gas units are similar, the cost in ETH is lower, and the mental model stays the same. Only the units of ETH per gas change.
Not financial advice. seapresale.xyz publishes market data and general information about digital assets. Crypto assets are volatile and you can lose everything you put in. Nothing here is a recommendation to buy, sell or hold, and we make no price predictions.
Prices are sourced from third parties and may be delayed or wrong. Verify anything you intend to act on against a primary source.