Home › Learn › DeFi Safety
DeFi Safety

What is Gas fees?

The transaction fee you pay to the network to have a transaction processed and included on-chain.

How it works

Every write to the blockchain costs gas, paid in the native token. Fees rise with network congestion. On a swap, gas is separate from slippage and any token taxes — budget for all three.

Example

In practiceA simple token swap on a busy network might cost more in gas than the trade is worth for a small amount — so you wait or batch.

Why did my transaction cost more than expected?

Congestion raised the gas price, or you set an aggressive fee. Gas, slippage, and token taxes are three separate costs.

Go deeper: DeFi From Scratch

The complete, step-by-step guide — every command, config, and the reasoning behind it.

Get the guide