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#
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.
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.
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:
| Label | Hook |
|---|---|
| No hook | None |
| Dynamic fee | Socket's DynamicFeeHook |
| TWAP oracle | Socket's TwapHook |
| Range order | Socket's RangeOrderHook |
| External hook | A 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#
| Mode | You fix | Your limit protects |
|---|---|---|
| Exact input | The amount you pay | The least you'll receive |
| Exact output | The amount you receive | The 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:
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.