What are gas fees
What are gas fees
Gas fees are the cost of executing operations on a blockchain. Every on-chain action — sending tokens, calling a smart contract, deploying code, recording data — requires computational work from the network's validators. Gas is the unit that measures this computational work, and the gas fee is what the user pays to compensate validators for performing it.
Gas serves two purposes: it rewards validators for processing transactions and it prevents spam by making it economically impractical to flood the network with frivolous operations. Without gas fees, anyone could submit unlimited transactions, overwhelming the network.
In short: gas fees are the price of on-chain computation — and in the crypto AI space, they are a critical constraint on what can economically happen on-chain versus what must remain offchain.
How gas fees work
The mechanics of gas vary across blockchains, but the core concept is consistent: users pay for the computational resources their transactions consume. The Ethereum model is the most widely referenced and serves as a useful baseline for understanding gas across all networks.
Gas in the Ethereum model
Ethereum measures gas in units called gwei (one billionth of an ETH). Each operation in the Ethereum Virtual Machine (EVM) has a fixed gas cost. Simple operations (adding two numbers) cost little gas; complex operations (writing data to storage) cost more. A transaction's total gas consumption is the sum of all the operations it triggers.
Key parameters in an Ethereum transaction:
- Gas limit — the maximum amount of gas the sender is willing to spend on the transaction. If the transaction requires more gas than the limit, it fails (reverts), but the sender still pays for the gas consumed up to that point. Setting the gas limit too low causes failures; setting it too high wastes nothing (unused gas is refunded) but signals willingness to pay more.
- Base fee — a per-block minimum fee set by the network protocol, adjusted automatically based on network congestion. When blocks are more than 50% full, the base fee increases; when they are less than 50% full, it decreases. The base fee is burned (destroyed), not paid to validators.
- Priority fee (tip) — an optional additional fee paid directly to the validator who includes the transaction in a block. Higher tips incentivize faster inclusion during periods of high demand.
- Max fee — the absolute maximum the sender is willing to pay per unit of gas (base fee + priority fee combined).
The actual fee paid is: gas used × (base fee + priority fee). If the max fee exceeds the actual cost, the difference is refunded.
EIP-1559 and fee burning
Ethereum's EIP-1559 upgrade (August 2021) introduced the base fee / priority fee split and the burning mechanism. Before EIP-1559, gas fees were set through a simple auction: users bid, and validators picked the highest bids. This led to volatile and unpredictable pricing. EIP-1559 made base fees algorithmically predictable while still allowing tips for priority.
The burning of the base fee means that a portion of every transaction's cost is permanently removed from circulation, creating a deflationary pressure on ETH supply. This mechanism is specific to Ethereum and does not apply to all blockchains.
Fee models on other chains
Different blockchains implement different fee structures, each with trade-offs:
- Solana — uses a fixed base fee per signature (very low) plus optional priority fees. Transaction costs are typically fractions of a cent, making Solana suitable for high-frequency, low-value transactions.
- BNB Smart Chain — uses an EVM-compatible gas model similar to Ethereum but with lower base fees due to higher block capacity and fewer validators.
- Arbitrum and other L2s — Layer 2 networks execute transactions on their own chain but post compressed transaction data to Ethereum (L1) for security. Users pay L2 execution fees (low) plus a share of the L1 data posting cost. The result is significantly cheaper than executing directly on Ethereum.
- Bitcoin — fees are based on transaction size in bytes, not computational complexity. Larger transactions (more inputs and outputs) cost more. Fees fluctuate based on mempool congestion.
- Avalanche — uses a fee model similar to Ethereum's EIP-1559 with dynamic base fees that adjust based on network demand. Fees are burned.
Why fees fluctuate
Gas fees are driven by supply and demand. Block space is a finite resource — each block can contain only a limited amount of computation. When demand for block space exceeds supply (during token launches, NFT mints, market volatility, or airdrop claims), fees spike. When demand is low, fees drop. This is analogous to surge pricing: the infrastructure has fixed capacity, and prices rise when everyone wants to use it simultaneously.
Why gas fees matter for crypto AI projects
Gas fees are one of the most significant constraints shaping the architecture of crypto AI projects. They determine what can practically happen on-chain and what must remain offchain.
AI computation is expensive on-chain
Running AI models — neural network inference, matrix multiplications, gradient calculations — requires enormous computational resources. Executing these operations inside a smart contract would consume vast amounts of gas, making it prohibitively expensive. A single neural network forward pass that costs fractions of a cent on a GPU could cost thousands of dollars in gas on Ethereum.
This is why virtually no crypto AI project runs its AI directly on-chain. Instead, the standard architecture is:
- AI computation happens offchain (on traditional servers, decentralized compute networks, or GPUs).
- Only the results, proofs, or checkpoints are recorded on-chain through transactions.
- The blockchain serves as the verification, settlement, and incentive layer, not the compute layer.
Understanding this architecture is essential for evaluating any project that claims to run "AI on blockchain." The gas cost constraint makes fully on-chain AI economically impractical on most current networks.
Gas costs as a design constraint
Gas fees influence how crypto AI projects design their on-chain components:
- Batch processing — instead of recording every individual AI inference on-chain, projects batch multiple results into a single transaction to amortize gas costs.
- Merkle roots and hashes — instead of storing full outputs, projects store cryptographic hashes or Merkle roots that can be used to verify outputs without storing the full data on-chain.
- L2 deployment — many AI projects deploy on Layer 2 networks (Arbitrum, Base, Optimism) to reduce gas costs while inheriting Ethereum's security.
- Chain selection — the choice of main chain is partly driven by gas economics. Projects requiring frequent on-chain interactions often choose low-fee chains like Solana or BNB Smart Chain over Ethereum mainnet.
Gas spending as an activity signal
Gas spending is observable and verifiable. When a project's smart contracts consume gas, it means real transactions are being processed. DecAIHub can examine a project's gas consumption patterns — volume, frequency, consistency — as one signal of genuine on-chain activity versus dormant or marketing-only projects.
Where this appears in DecAIHub project cards
Gas fees are not listed as a standalone field in project cards, but they directly influence several fields:
- Main chain — the choice of chain determines the gas fee structure. A project on Ethereum mainnet faces fundamentally different cost economics than one on Solana or an L2.
- Type — L2 projects exist partly to reduce gas fees. Understanding gas fees explains why the L1/L2 distinction matters.
- Onchain necessity — the assessment of Onchain necessity implicitly considers whether the project's on-chain activity justifies the gas costs involved. Minimal on-chain activity could indicate that gas costs make the on-chain component impractical.
- Token model (fee-mechanism) — some projects use their token to pay for gas-like fees within their own network or protocol, creating a token utility tied to computational demand.
What gas fees alone do not prove
- Usage quality — high gas spending does not prove the transactions are meaningful. Automated bots, wash trading, and spam transactions all consume gas without indicating genuine user demand.
- AI activity — gas consumption by a project's smart contracts does not prove that AI was involved. The contract could be executing simple token transfers, governance votes, or other non-AI operations.
- Cost efficiency — low gas fees on a chain do not mean the chain is better. Lower fees often reflect trade-offs in decentralization, security, or validator count. Gas cost is one factor among many.
- Sustainability — a project may subsidize gas costs during early phases to attract users. High on-chain activity during a subsidized period does not guarantee continued activity when users must pay full gas costs.
Do not confuse with
- Transaction — a transaction is the instruction submitted to the blockchain. Gas is the cost of processing that instruction. Every transaction costs gas, but they are different concepts.
- Token transfer fees — some tokens charge a fee on transfers (built into the token's smart contract logic). These are separate from blockchain gas fees and serve different purposes.
- Network fees — "network fees" is sometimes used as a synonym for gas fees, but it can also refer to protocol-level fees in specific projects (bridge fees, DEX fees). Context matters.
- Ethereum — while gas is most commonly associated with Ethereum, virtually all blockchains have some form of transaction fee. Gas is not exclusive to Ethereum; it is a universal blockchain concept.
Frequently asked questions
Why are Ethereum gas fees so high?
Ethereum's gas fees reflect the high demand for limited block space on the most widely used smart contract platform. Ethereum's block size and block time create a ceiling on how many transactions can be processed per second. When demand exceeds this capacity — during popular token launches, NFT mints, or DeFi activity spikes — fees rise. This is one of the primary motivations for Layer 2 networks and alternative chains.
Can gas fees be avoided?
On most blockchains, on-chain transactions require gas fees — they are a fundamental feature, not a bug (fully feeless networks are rare). However, gas costs can be minimized by using Layer 2 networks, choosing low-fee chains, batching operations, timing transactions during low-demand periods, or structuring applications to minimize on-chain interactions. Some projects also offer transactions that are "gasless" for the user, where the project pays gas fees on behalf of users through relayer services.
How do gas fees affect AI on blockchain?
Gas fees are the primary reason AI computation does not happen directly on-chain. The cost of executing AI model inference in a smart contract would be orders of magnitude higher than running the same computation on a standard GPU. This economic reality shapes the hybrid architecture used by virtually all crypto AI projects: offchain compute with on-chain verification and settlement.
External references
- Ethereum.org — Gas and fees — the Ethereum Foundation's comprehensive guide to gas mechanics, EIP-1559, and fee estimation
- Etherscan Gas Tracker — real-time Ethereum gas fee monitoring and historical data
- L2Fees.info — comparison of transaction costs across Ethereum Layer 2 networks
No comments to display
No comments to display