Ethereum Gas Calculator
Calculate Ethereum transaction costs in gwei, ETH, and USD. Understand gas limits, base fees, priority fees (EIP-1559), and compare costs for different transaction types.
⛽Gas Price (EIP-1559)
Gas Limit (Transaction Type)
ETH Price
Total Cost
$1.42
EIP-1559 Fee Breakdown
This amount is permanently destroyed, reducing ETH supply
This goes to the validator who includes your transaction
Cost Comparison by Speed
| Speed | Time | Gas Price | Cost (ETH) | Cost (USD) |
|---|---|---|---|---|
| Slow | ~5 min | 23.5 gwei | 0.000494 ETH | $1.23 |
| Standard | ~1 min | 27.0 gwei | 0.000567 ETH | $1.42 |
| Fast | ~15 sec | 35.0 gwei | 0.000735 ETH | $1.84 |
| Instant | Next block | 47.5 gwei | 0.000997 ETH | $2.49 |
* Estimates based on current base fee. Actual costs may vary with network conditions.
Cost by Transaction Type
Gas Price Context
Tips for Current Gas Level
Gas prices are at normal levels. Proceed with regular transactions. For non-urgent operations, waiting for off-peak hours could save 20-30%.
Layer 2 Alternative Costs
Estimated costs for the same transaction on Layer 2 networks:
* L2 costs are estimates and vary based on L2-specific gas prices. Bridge costs not included.
Related Calculators
Related Calculators
About This Calculator
"Why did my Ethereum transaction cost $50?" If you have ever sent ETH, swapped tokens on Uniswap, or minted an NFT, you have asked this question. Ethereum gas fees can be confusing, unpredictable, and at times painfully expensive. This Ethereum Gas Calculator helps you understand exactly what you will pay before you click "confirm."
Gas is the unit of computational effort required to execute operations on the Ethereum network. Every transaction, from a simple ETH transfer to a complex smart contract interaction, requires gas. The total cost depends on three factors: the gas limit (how much computation your transaction needs), the gas price (how much you are willing to pay per unit of gas in gwei), and the current network demand.
Since the London Hard Fork in August 2021 and the implementation of EIP-1559, Ethereum gas fees work differently. Instead of a single gas price, you now have a base fee (determined by the network and burned) plus an optional priority fee (tip to validators). Understanding this system is crucial for timing your transactions and avoiding overpaying. During the 2021 NFT boom, users paid over $200 for a single Uniswap swap. In calmer periods, the same transaction costs under $5. The difference? Knowing when and how to transact.
How to Use the Ethereum Gas Calculator
- 1**Enter the gas price in gwei**: Check current gas prices on Etherscan or use our suggested slow/standard/fast presets based on network conditions.
- 2**Select or enter a gas limit**: Choose from presets for common transactions (ETH transfer: 21,000, ERC-20: 65,000, Swap: 150,000, NFT Mint: 200,000) or enter a custom value.
- 3**Enter the current ETH price**: Use the auto-fetch feature to get the live ETH/USD price, or enter manually if you want to calculate for a specific price point.
- 4**Review the base fee and priority fee breakdown**: Understand how EIP-1559 splits your gas cost between the burned base fee and validator tip.
- 5**Compare costs across speed tiers**: See how much you would pay for slow, standard, and fast transaction speeds.
- 6**Check historical context**: Compare current gas prices to recent averages to determine if now is a good time to transact.
- 7**Consider Layer 2 alternatives**: For non-urgent transactions, review the L2 comparison to see potential savings on Arbitrum, Optimism, or other rollups.
Formula
Transaction Cost = Gas Limit x (Base Fee + Priority Fee) x ETH PriceEthereum transaction costs are calculated in three steps. First, determine the gas limit (the maximum gas units your transaction can consume). For simple transfers, this is fixed at 21,000. For smart contracts, it varies based on complexity. Second, calculate the gas price in gwei by adding the base fee (set by the network) and your priority fee (tip to validators). One gwei equals 0.000000001 ETH. Finally, multiply gas limit by gas price to get the cost in ETH, then convert to USD using current ETH prices.
Understanding Ethereum Gas: The Complete Guide
What Is Gas and Why Does It Exist?
Gas is the unit measuring computational effort on Ethereum. Every operation, from adding two numbers to storing data on-chain, has a gas cost. This system prevents infinite loops, spam attacks, and ensures validators are compensated for their work.
The Three Components of Gas:
| Component | Description | Example |
|---|---|---|
| Gas Limit | Maximum gas units your transaction can use | 21,000 for ETH transfer |
| Gas Price | Amount paid per gas unit (in gwei) | 30 gwei |
| Gas Used | Actual gas consumed (less than or equal to limit) | 21,000 (exact for transfers) |
Why Gas Prices Fluctuate:
Ethereum blocks have limited space (approximately 15-30 million gas per block). When demand exceeds supply, users bid higher gas prices to get included faster. During NFT drops, token launches, or market volatility, gas can spike 10-50x normal levels.
Common Gas Costs by Transaction Type:
| Transaction | Gas Limit | At 30 gwei | At 100 gwei |
|---|---|---|---|
| ETH Transfer | 21,000 | ~$1.50 | ~$5.00 |
| ERC-20 Transfer | 65,000 | ~$4.50 | ~$15.00 |
| Uniswap Swap | 150,000 | ~$10.50 | ~$35.00 |
| NFT Mint | 200,000 | ~$14.00 | ~$47.00 |
| Complex DeFi | 500,000 | ~$35.00 | ~$117.00 |
Assumes ETH price of $2,500
EIP-1559 Explained: Base Fee vs Priority Fee
The London Hard Fork Revolution
Before August 2021, Ethereum used a simple auction: highest bidder wins. This led to extreme overpayment and unpredictable fees. EIP-1559 introduced a dual-fee system:
Base Fee (Burned):
- Algorithmically determined by the network
- Increases when blocks are more than 50% full
- Decreases when blocks are less than 50% full
- Adjusts up to 12.5% per block
- Permanently destroyed (burned), making ETH deflationary
Priority Fee (Tip to Validators):
- Optional payment directly to the validator
- Incentivizes validators to include your transaction
- Higher tips = faster inclusion
- Typically 1-2 gwei for normal transactions
- Can spike to 10-50+ gwei during network congestion
How It Works in Practice:
| Scenario | Base Fee | Priority Fee | Total Gas Price |
|---|---|---|---|
| Low demand | 10 gwei | 1 gwei | 11 gwei |
| Normal | 25 gwei | 2 gwei | 27 gwei |
| High demand | 80 gwei | 5 gwei | 85 gwei |
| Extreme congestion | 200 gwei | 30 gwei | 230 gwei |
Max Fee vs Max Priority Fee:
When submitting a transaction, you set:
- Max Fee: The absolute maximum you will pay (base + priority)
- Max Priority Fee: The maximum tip for validators
If the base fee is lower than expected, you only pay actual base fee + priority fee, not your max fee. The difference is refunded.
Example: Max Fee = 50 gwei, Max Priority Fee = 2 gwei, Actual Base Fee = 25 gwei
- You pay: 25 (base) + 2 (priority) = 27 gwei
- Refunded: 50 - 27 = 23 gwei equivalent
Gas Limits for Common Transactions
Understanding Gas Limits
Gas limit is the maximum amount of gas your transaction can consume. Setting it too low causes the transaction to fail (and you still pay for the gas used). Setting it too high wastes nothing, unused gas is refunded.
Standard Gas Limits:
| Transaction Type | Gas Limit | Notes |
|---|---|---|
| ETH Transfer | 21,000 | Fixed, never changes |
| ERC-20 Token Transfer | 45,000-65,000 | Varies by token contract |
| ERC-20 Approval | 45,000-50,000 | One-time per token/protocol |
| Uniswap V3 Swap | 120,000-180,000 | Depends on route complexity |
| SushiSwap | 130,000-160,000 | Similar to Uniswap |
| 1inch Aggregator | 200,000-400,000 | Routes through multiple DEXs |
| NFT Mint (ERC-721) | 150,000-250,000 | Varies by contract complexity |
| NFT Mint (ERC-1155) | 100,000-200,000 | More gas-efficient standard |
| OpenSea Listing | 80,000-120,000 | First listing costs more |
| Aave Deposit | 200,000-300,000 | DeFi lending |
| Compound Borrow | 300,000-500,000 | Complex DeFi operation |
| Curve Swap | 150,000-400,000 | Depends on pool |
Why Gas Limits Vary:
Smart contract gas usage depends on:
- Storage Operations: Writing to blockchain storage is expensive (~20,000 gas per 32 bytes)
- Computation Complexity: Loops, conditionals, and math operations
- External Calls: Interacting with other contracts
- State Changes: Modifying contract variables
Pro Tip: Most wallets estimate gas limits automatically. Add 10-20% buffer for complex transactions to avoid failures.
When to Transact: Timing Your Ethereum Transactions
Gas Price Patterns
Ethereum gas prices follow predictable patterns based on global activity:
Weekly Patterns:
| Day | Relative Gas Cost | Best For |
|---|---|---|
| Monday | High (+20-30%) | Avoid if possible |
| Tuesday-Thursday | Medium | Normal transactions |
| Friday | Medium-High | Pre-weekend activity |
| Saturday | Low (-20-40%) | Large transactions |
| Sunday | Lowest (-30-50%) | Best for DeFi, NFTs |
Daily Patterns (UTC):
| Time (UTC) | Gas Level | US Time | Asia Time |
|---|---|---|---|
| 00:00-06:00 | Low | Evening | Morning |
| 06:00-12:00 | Medium | Night/Morning | Afternoon |
| 12:00-18:00 | High | Morning/Afternoon | Evening/Night |
| 18:00-24:00 | Medium-High | Afternoon/Evening | Night |
Best Times to Transact:
- Optimal: Sunday 02:00-06:00 UTC (Saturday night in US)
- Good: Weekends generally, early morning UTC
- Avoid: Monday mornings, major market opens, NFT drops
Gas Spike Events:
| Event | Typical Impact | Duration |
|---|---|---|
| Popular NFT Drop | 5-50x normal | Minutes to hours |
| Token Launch | 3-20x normal | Hours |
| Market Crash/Pump | 2-10x normal | Hours to day |
| Airdrop Claim | 2-5x normal | Hours |
Strategy: For non-urgent transactions, set a max fee at 80% of current levels and wait. Your transaction will execute when gas drops.
Layer 2 Solutions: Dramatically Reduce Gas Costs
What Are Layer 2s?
Layer 2 solutions process transactions off the Ethereum mainnet, then batch them together for settlement. This dramatically reduces per-transaction costs while maintaining Ethereum security.
L2 Cost Comparison (Uniswap Swap):
| Network | Typical Cost | Savings vs Mainnet |
|---|---|---|
| Ethereum Mainnet | $10-50 | Baseline |
| Arbitrum One | $0.10-0.50 | 95-99% |
| Optimism | $0.10-0.50 | 95-99% |
| zkSync Era | $0.05-0.30 | 97-99% |
| Base | $0.05-0.20 | 98-99% |
| Polygon (PoS) | $0.01-0.05 | 99%+ |
When to Use L2s:
| Situation | Recommendation |
|---|---|
| Frequent trading | Always use L2 |
| Small transactions (<$500) | Strongly prefer L2 |
| Large, infrequent transactions | Mainnet acceptable |
| NFT minting/trading | L2 if collection supports it |
| DeFi yield farming | L2 for most protocols |
| High-security needs | Mainnet for maximum security |
How to Bridge to L2:
- Official Bridges: Cheapest but can take 7+ days to withdraw
- Third-Party Bridges: Faster but slightly higher fees (Hop, Across, Stargate)
- CEX Withdrawals: Many exchanges now support direct L2 withdrawals
L2 Considerations:
- Liquidity: Some pairs have less liquidity on L2
- Protocol Support: Not all DeFi protocols are on L2
- Withdrawal Time: Optimistic rollups have 7-day withdrawal delays
- Bridge Costs: Factor in bridge costs for round trips
Break-Even Analysis:
If mainnet swap costs $20 and L2 costs $0.50 + $5 bridge each way:
- Single swap: L2 costs $10.50 (still cheaper)
- 10 swaps: L2 costs $15 vs mainnet $200
- 100 swaps: L2 costs $60 vs mainnet $2,000
For frequent traders, L2s are essential.
Gas Optimization Strategies
Reduce Your Ethereum Gas Costs
1. Transaction Timing
- Monitor gas trackers (Etherscan, GasNow)
- Set alerts for low gas periods
- Use "slow" option for non-urgent transactions
- Avoid transacting during NFT drops and market volatility
2. Batch Transactions
- Combine multiple token transfers into one transaction
- Use DeFi aggregators that batch operations
- Wait to accumulate multiple actions before executing
3. Choose Gas-Efficient Protocols
- Some DEXs are more gas-efficient than others
- Newer protocols often have optimized contracts
- Check gas estimates before choosing a protocol
4. Token Approvals Strategy
| Approval Type | Gas Cost | Risk | Best For |
|---|---|---|---|
| Exact Amount | ~45,000 | Low | One-time transactions |
| Unlimited | ~45,000 | Higher | Frequent same-protocol use |
| Permit (EIP-2612) | 0 (gasless) | Low | Supported tokens |
5. Use Gas Tokens (Historical)
Gas tokens like CHI were used to tokenize gas during low periods and spend during high periods. Post-EIP-3529, this strategy is largely obsolete, but understanding it shows how gas optimization evolved.
6. Contract Interaction Optimization
- Use "write" functions sparingly (they cost gas)
- "Read" functions are free
- Batch reads before writes to avoid failed transactions
7. Wallet Settings
- Set reasonable max fees (not 10x current)
- Use wallets with good gas estimation (MetaMask, Rabby)
- Enable EIP-1559 for more predictable pricing
Potential Savings:
| Strategy | Typical Savings |
|---|---|
| Timing optimization | 20-50% |
| Protocol choice | 10-30% |
| Batching | 30-50% |
| L2 migration | 90-99% |
Historical Gas Price Context
Ethereum Gas Through the Years
Understanding historical gas prices provides context for current levels:
Gas Price Milestones:
| Period | Average Gas (gwei) | Notable Events |
|---|---|---|
| 2017 | 20-50 | ICO boom |
| 2018 | 5-20 | Bear market calm |
| 2019 | 5-15 | DeFi Summer begins |
| 2020 (DeFi Summer) | 100-500 | Yield farming craze |
| 2021 (NFT Boom) | 50-300 | Bored Apes, OpenSea surge |
| 2022 (Post-Merge) | 10-50 | Proof of Stake transition |
| 2023 | 15-40 | L2 adoption growing |
| 2024 | 10-30 | EIP-4844 (Proto-Danksharding) |
| 2025-2026 | 8-25 | Blob transactions, L2 dominance |
Extreme Events:
| Event | Peak Gas | Date |
|---|---|---|
| CryptoKitties Launch | 200 gwei | Dec 2017 |
| Black Thursday Crash | 500+ gwei | Mar 2020 |
| UNI Airdrop | 700 gwei | Sep 2020 |
| Bored Ape Launch | 400+ gwei | Apr 2021 |
| Otherside Mint | 8,000+ gwei | May 2022 |
Post-Merge Changes:
The Ethereum Merge (Sep 2022) did not directly reduce gas costs, but the transition to Proof of Stake:
- Made block times more consistent (exactly 12 seconds)
- Enabled future scaling upgrades
- Prepared for sharding and danksharding
EIP-4844 Impact (2024):
Proto-danksharding introduced "blob" transactions, dramatically reducing L2 costs:
- L2 fees dropped 10-100x
- Mainnet fees remained similar
- Blobs are temporary, reducing long-term storage costs
Current Context (2026):
Gas prices in 2026 reflect a mature ecosystem where:
- Most high-frequency activity has moved to L2s
- Mainnet is used for high-value, high-security transactions
- Average gas is 10-30 gwei during normal periods
- Spikes still occur during major events but are shorter-lived
Common Gas Mistakes and How to Avoid Them
Expensive Errors to Avoid
1. Setting Gas Limit Too Low
| Mistake | Consequence | Prevention |
|---|---|---|
| Using 21,000 for token transfer | Transaction fails, gas lost | Use wallet estimates + 20% |
| Copying limits from tutorials | Outdated estimates fail | Check current requirements |
| Ignoring contract upgrades | Changed gas requirements | Re-estimate after updates |
2. Overpaying on Gas Price
| Mistake | Consequence | Prevention |
|---|---|---|
| Using "fast" for non-urgent | 2-5x overpayment | Assess actual urgency |
| Not checking current gas | Paying 100 gwei when 20 is fine | Check before transacting |
| Panic during volatility | Extreme overpayment | Set max fee limits |
3. Failed Transaction Gas Loss
Common causes of failed transactions (you still pay gas):
- Slippage too low for swaps
- Approval not completed before swap
- Contract requires higher gas limit
- Nonce conflicts from pending transactions
4. Approval Confusion
| Issue | Problem | Solution |
|---|---|---|
| Approving wrong token | Wasted gas | Double-check token address |
| Multiple approvals | Unnecessary gas spend | Approve once, check limits |
| Revoking approvals constantly | Each revoke costs gas | Revoke only high-risk approvals |
5. Timing Mistakes
| Mistake | Cost |
|---|---|
| Trading during NFT drop | 5-50x normal fees |
| Swapping during liquidation cascade | 10x+ normal fees |
| Not waiting for gas to drop | 2-3x average fees |
Gas Safety Checklist:
- Checked current gas prices before transacting
- Using appropriate speed tier for urgency
- Gas limit includes safety buffer
- Not transacting during known high-gas events
- Considering L2 alternative for this transaction
- Token is approved before attempting swap
- No pending transactions that could cause nonce issues
Pro Tips
- 💡Check gas prices before transacting. A 5-minute wait can sometimes save 50% or more if a spike is subsiding.
- 💡Use the "slow" gas option for non-urgent transactions. The difference between 30 seconds and 5 minutes confirmation rarely matters for most DeFi operations.
- 💡Consider Layer 2 networks for frequent trading. The one-time bridge cost is quickly offset by 95-99% lower transaction fees.
- 💡Batch your transactions when possible. Approving and swapping in one session is more efficient than doing them on different days.
- 💡Time large transactions for weekend mornings (UTC). Gas prices are consistently 30-50% lower during this window.
- 💡Set your max fee reasonably, not excessively high. You only pay the actual base fee + priority, but a sky-high max fee signals desperation.
- 💡Use gas-efficient DEX aggregators like 1inch or Paraswap. They often find routes that are both cheaper in price and gas.
- 💡Revoke unused token approvals periodically but strategically. Each revocation costs gas, so only revoke high-risk or deprecated protocols.
- 💡Keep some ETH always available for gas. Running out of ETH to pay gas when you need to exit a position urgently is costly.
- 💡Avoid transacting during popular NFT drops or token launches. Wait 30-60 minutes for gas to normalize after these events.
- 💡Use gas estimation tools in your wallet and add a 20% buffer for complex transactions to avoid failures.
- 💡Consider using a wallet with built-in gas optimization features like Rabby, which often suggests better gas prices than MetaMask defaults.
Frequently Asked Questions
Gwei is a denomination of Ethereum, similar to how cents relate to dollars. One gwei equals 0.000000001 ETH (one billionth of an ETH), or 10^-9 ETH. The name comes from "giga-wei," where wei is the smallest unit of ETH. Gas prices are quoted in gwei because the numbers are more manageable. For example, a gas price of 30 gwei is easier to work with than 0.00000003 ETH. To convert gwei to ETH: divide by 1,000,000,000. To calculate transaction cost: Gas Limit x Gas Price (gwei) / 1,000,000,000 x ETH Price.

