Skip to content

Uniswap v4 Hooks ๐ŸŒŠ

@sealaunch@sealaunch17 charts

Uniswap v4 Hooks

Uniswap v4 introduces Hooks, a system that allows developers to customize and extend the behavior of liquidity pools. Docs

Hooks are external smart contracts that can be attached to individual pools. Every pool can have one hook but a hook can serve an infinite amount of pools to intercept and modify the execution flow at specific points during pool-related actions.

Hook Explorer

Check any hook stats by selecting below the hook address and running the dashboard.

image

Core Hook Functions

Uniswap v4 provides a set of core hook functions that can be implemented by developers. Below is a diagram showing how each of the 14 bits correspond to a hook function.

We deliver onchain market intelligence across onchain credit, yields, RWAs, and stablecoins for protocols and institutions operating in onchain capital markets.

Check our Dune work and learn more at sealaunch.xyz. DM us on X for inquiries.

beforeInitialize: Called before a new pool is initialized.

afterInitialize: Called after a new pool is initialized.

beforeAddLiquidity: Called before liquidity is added to a pool.

afterAddLiquidity: Called after liquidity is added to a pool.

beforeRemoveLiquidity: Called before liquidity is removed from a pool.

afterRemoveLiquidity: Called after liquidity is removed from a pool.

beforeSwap: Called before a swap is executed in a pool.

afterSwap: Called after a swap is executed in a pool.

beforeDonate: Called before a donation is made to a pool.

afterDonate: Called after a donation is made to a pool.