Gas Fee
The cost paid to a blockchain network to process a transaction.
Also called: gas · network fee · transaction fee
Written by Javier Sánchez Ros
In plain language
Gas compensates the network for computation and block space. Fees are set by demand, so they spike when the network is busy.
On decentralized exchanges gas is charged per transaction regardless of trade size, which makes small trades disproportionately expensive.
Fees are paid whether or not a transaction succeeds. A failed swap still costs gas.
Worked through
The same $12 of gas on a $40 swap and on a $4,000 swap
- Gas cost
- $12 (both)
- On a $40 swap
- 30% of the trade
- On a $4,000 swap
- 0.3% of the trade
- Failed transaction
- still costs $12
Gas does not scale with trade size. It is a flat charge for block space, so the smaller the trade, the larger the share of it that goes to the network. On the $40 swap, price has to move 30% in your favour just to get back to even — and then another 30% to get out again.
That sets a practical floor under on-chain trading that has nothing to do with strategy. Below a certain size the fee is the trade, and no amount of correct analysis rescues it.
The last line is the one people meet the hard way. Gas pays for the attempt, not the result. A swap that reverts because the price moved while it was pending still costs the full fee, and during congestion — which is exactly when swaps revert — that fee is at its highest.
Why it matters
Gas is a fixed cost per trade rather than a percentage. It sets a practical minimum trade size below which the fee consumes the expected profit.
Common mistakes
- Ignoring gas when calculating whether a small on-chain trade is worth making.
- Trading during network congestion without checking current fee levels.
Keep exploring
These concepts are connected. Understanding one usually makes the next one easier.
The gap between the bid and the ask — the built-in cost of entering a trade.
How easily an asset can be bought or sold without moving its price.
A market where assets are bought and sold for immediate delivery and full ownership.
Any cryptocurrency other than bitcoin.
A crypto asset designed to hold a fixed value, usually one US dollar.