swap fee 0.3%

AMM // automated market maker

A decentralized exchange (DEX) has no middleman

A DEX such as Uniswap or PulseX runs on an automated market maker (AMM): it trades from a pool, a smart contract holding two tokens. Anyone can trade with it: put one token in, take the other out. No order book, no company holding your money, nobody setting prices. A formula does the work.

$ amm --pool

design
constant product, x · y = k
swap fee
0.3% here; each DEX sets its own
price
ratio of the two balances
used by
Uniswap v2 and forks such as PulseX
  1. A classic exchange needs a seller on the other side. Here a contract always trades.
  2. It holds two tokens. In our example: 100,000 of token A and 200,000 of token B.
  3. Anyone can trade: put one token in, take the other one out.
  4. No order book and nobody setting prices. One formula does it all.

Sources // verified 2026-11-14

Controls

The caption under each animation explains what is happening; its dots jump between the steps. Arrow keys or a swipe change slides, Shift + arrows scrub by 2 s, J and L by 5 s, Space or K pauses, R repeats the current slide, S slows playback down (1/2, 1/3, 1/4, 1/6 of normal speed, then back), M turns the sound, music and event sounds, on or off (it starts off), F toggles full screen, keys 1–9 and 0 jump to a slide. You can grab the progress bar and drag it.

Speed

Effects

Auto picks full, balanced or lite effects for your device and lowers them while running if the animation falls behind. It respects the system's reduced-motion setting, and the choice also applies to the rest of Cryptospecting. Current: auto.

Tokens A and B and the example pools are made up, with round numbers so the arithmetic is easy to follow. The swap maths is that of the Uniswap v2 contracts, which many DEXs reuse; fees and their split differ by DEX. Not financial advice.