Skip to main content
Volver al glosario
Fundamentals
Intermediate

Gas Limit

También conocido como: Transaction Gas Limit, Block Gas Limit

The maximum amount of computational work a user is willing to pay for in a transaction, or the maximum gas allowed in a single block.

Gas limit has two meanings in blockchain: the maximum gas units a user allocates for a specific transaction, and the maximum total gas allowed across all transactions in a single block. Both serve as caps to prevent runaway costs and infinite loops.

Transaction Gas Limit:

Every transaction specifies a gas limit, which is the maximum amount of gas the sender is willing to consume. If the transaction completes before using all the gas, the unused portion is refunded. If it runs out of gas before completing, the transaction fails (reverts), but the gas used is still charged.

Common Gas Limits:

OperationGas RequiredTypical Limit Set
ETH transfer21,00021,000
ERC-20 transfer~65,00080,000
Uniswap swap~150,000200,000
NFT mint~100,000-300,000350,000
Complex DeFi tx~500,000+700,000+

Block Gas Limit:

Each block has a maximum gas capacity (currently ~30M gas on Ethereum). This limits how many transactions can fit in one block. When demand exceeds capacity, transactions compete for inclusion by offering higher gas prices.

What Happens When Gas Limit Is Wrong:

ScenarioResult
Limit too lowTransaction fails, gas fee still charged
Limit too highTransaction succeeds, excess gas refunded
Exactly rightTransaction succeeds, no waste

Practical Tips: - Most wallets automatically estimate gas limits based on the transaction type - Complex contract interactions may need manual gas limit increases - If a transaction consistently fails with "out of gas," increase the limit - Never manually lower the gas limit below the estimated minimum - Some wallets show a gas estimate before you confirm, which is the lower bound

Relationship to Gas Price: Gas limit and gas price are different. The limit is how much work you allow, the price is how much you pay per unit of work. Total fee = gas used x gas price. Setting a high limit does not cost more unless the transaction actually uses that gas.

Términos relacionados

Análisis cripto relacionados

Explora cómo Gas Limit se aplica a estas criptomonedas con un análisis STRICT detallado.

Última actualización: 3/4/2026