Skip to content
Kriptofoni
Crypto GlossaryBlockchain & Technology

What Is Gas Limit?

Also known as: Gas Cap, Block Gas Limit, Transaction Gas Limit

In short

Gas limit is the maximum amount of gas a transaction is allowed to use on Ethereum and EVM-compatible networks; the term also refers to the block gas limit, which caps the total computational work that can fit in a block.

On Ethereum, every transaction requires a certain amount of computation, and this work is measured in units of gas. A simple ETH transfer uses 21,000 gas, while a smart contract interaction can require much more. When sending a transaction, the user sets a gas limit; wallets usually fill in this value automatically based on estimated usage. When the transaction is completed, only the gas actually used is charged.

If the limit is set too low, the transaction fails with an out of gas error and the changes made are reverted; however, the gas fee spent up to that point is not refunded. This limit also prevents faulty contracts or those that enter an infinite loop from draining a user's balance without bound.

The block gas limit, on the other hand, determines the total capacity the network can process in each block. This value can be changed gradually through validators' preferences; raising it increases the network's capacity but also raises the hardware requirements of running a node. With EIP-1559, blocks have gained a structure that flexes around a target fullness level.

Last updated: · This content is for information purposes only and is not investment advice.

Related terms