SocketDocs

Use the app

Swap

Socket quotes your trade on every route through Uniswap v4 pools with no hook or a listed hook, and executes the best one through the Universal Router with a limit you sign.

Quote every route#

A pair can have many pools on Uniswap v4: one with no hook, one with Socket's dynamic fee, one with its TWAP oracle, one holding range orders, each with its own fee and tick spacing. They hold separate liquidity and quote different amounts. Enter an amount on Swap and the app quotes the trade on every route it can take, with Uniswap's Quoter, and lists the routes side by side.

A route is one pool, or several pools one after another. The route marked Best is chosen for you:

  • For an exact-input trade, the route that pays out the most.
  • For an exact-output trade, the route that asks for the least input.

You can pick any other route in the list.

Swap#

  1. Pick the tokens

    Choose what you pay and what you receive. ETH is native in Uniswap v4 pools, so you trade the ETH in your wallet as it is, with nothing wrapped.

  2. Enter an amount

    Type in the top field to fix what you pay, or in the bottom field to fix what you receive. The routes and the receipt update as you type.

  3. Swap

    Press Swap. The first time you sell an ERC-20 token, approve Permit2 for it. Then sign the permit and confirm the transaction. The Universal Router runs every swap of the route in that one transaction.

Which pools the app uses#

The app routes only through pools with no hook or with a hook on Socket's allowlist. The allowlist is kept on chain in Socket's HookRegistry, and SOCKET holders vote it on Govern. Each pool on a route shows its hook:

LabelHook
No hookNone
Dynamic feeSocket's DynamicFeeHook
TWAP oracleSocket's TwapHook
Range orderSocket's RangeOrderHook
External hookA listed hook from another author, marked in mustard

A pool whose hook isn't listed is never quoted. See Routing for the same check from a contract.

Exact input or exact output#

ModeYou fixYour limit protects
Exact inputThe amount you payThe least you'll receive
Exact outputThe amount you receiveThe most you'll pay

Slippage#

Slippage is the room you allow between the quote and the execution. The app turns it into a limit inside the transaction you sign: a minimum output for exact input, a maximum input for exact output. The Universal Router checks it after the route's last swap. If the result misses it, the transaction reverts and only the gas is spent.

Set it under Slippage. The setting is remembered in this browser.

The receipt#

Under the form, the chosen route is printed as a receipt: each pool with its hook and fee, the price impact, the gas in ETH, and the limit you sign. Each swap through a pool on a Socket hook runs in this order:

  1. Pool keyRouterNames the pool: two currencies, the fee, the tick spacing and the hook address. The address's last 14 bits say which calls PoolManager makes.
  2. Before swapHook, flag 128Reads the pool. In a dynamic-fee pool it may return this swap's LP fee; with flag 8 it may also return a delta.
  3. SwapPoolManagerMoves the price through the active ranges and accrues the LP fee. No hook runs here.
  4. After swapHook, flag 64Sees the result. With flag 4 it may take from or add to the swap's other side. The range-order hook takes filled orders out here.
  5. SettleRouterPays what the swap owes and takes what it is owed, once, at the end of the unlock. Below the swapper's minimum output, it reverts.
If any stop reverts, the whole transaction reverts: no fee taken, no price moved, no tokens sent.

After the swap confirms, the receipt links the transaction on the explorer.

Fees#

A swap pays the pool's LP fee, taken from the token you pay with. A pool with no dynamic fee has its fee fixed in its pool key. A Dynamic fee pool's hook sets the fee for each swap before it runs: the pool's base fee plus an extra that follows recent price movement, never above the pool's max fee. See Dynamic fee.

The Quoter runs a swap exactly as it would execute, hooks included, so a dynamic-fee quote carries the fee at that moment. The fee decays every second and rises after swaps move the price. Your limit covers the difference.

Swappers pay the pool's fee and nothing more. The SOCKET buyback takes its share from the fees LPs collect, so it never changes a quote. See Provide liquidity.

Range orders on a route#

Range orders are liquidity in their pool like any other position, and a swap through a Range order pool trades against them. The swap that takes the price all the way through an order also takes that order out of the pool.

Sell at a price#

Sell at a price places a range order instead of swapping now. Your tokens go into the pair's Range order pool just above the price you set, and sell as the market crosses it. See Place a range order.

Public documentation snapshot · 9 October 2026 · Original page ↗
LOCAL REPLICA · DOCUMENTATION SNAPSHOT