Skip to content
Solana
FEEIn the programBit 8

Storm Fee

The fee rises when price turns choppy and eases as it calms, within fixed bounds.

Where it runs

Fee

Sets or adds to what the swap pays.

Status on reel

In the program

In the reel program: bit 8 of PoolParams.blocks, frozen at PoolInit (PROGRAM.md §5).

Set by

You, at launch

Frozen in PoolParams at PoolInit; nobody can change it after.

What it does

Every few minutes the pool samples how far price moved; the fee steps toward a level set by recent movement and steps back down as it calms. Every swap pays the same level until the next sample. Nobody sets the level: only the floor and the ceiling are chosen at launch.

How it works on reel

Fixed 300 s samples. At a sample's close, target = floor + (ceiling − floor)·min(1, maxdev/500 bps) and level += (target − level)/2; each idle sample halves the gap to the floor (up to 16). Every swap pays the level, protocol share first.

Settings · 3

SettingMinDefaultMaxWhat it does
Ceiling
storm_ceiling_pips
0.05%0.6%10%The highest level choppy markets can lift the fee to.Grid 0.05%
Floor
storm_floor_pips
0%0%See ruleThe level a calm market eases back to.At most the ceiling.Grid 0.05%
Paid to
storm_to
LP feeLP feeLiquidity ownerWhere the fee goes after reel's share.0 LP fee · 1 Liquidity owner

Fees and who's paid

Paid to

LPs by default, or the liquidity owner, after reel's share.

Protocol share

reel's protocol share s (20–50%, fixed at launch) comes off each charge first.

Requires and can't be combined with

Requires

No other block.

Can't be combined with

Worked example

Ceiling 0.6%, floor 0: a sample with a 5% swing sets the target to 0.6% and the level to 0.3%. A 1 SOL swap then pays 0.003 SOL: 0.0006 SOL to reel, 0.0024 SOL to LPs.

Solana notes

It works as on hookr; amounts are in SOL or the pool's quote, and times in seconds.

On hookr: Core block · Live

Other blocks in Fees