{"uid":"cap_lo2QrOb2XDwf-8XXoxLaC","slug":"base-network-gas-price-transaction-cost-estimator-5e351e84","name":"Base Network Gas Price & Transaction Cost Estimator","description":"Use when an agent must price or time a Base transaction. Input: none. Output: JSON current and next base fee, priority fee tiers (slow/standard/fast from the last 20 blocks), suggested maxFeePerGas, block fullness, and typical cost of an ETH transfer, ERC-20 transfer/approve, DEX swap, NFT mint and contract deploy (L2 fee + L1 data fee) in ETH and USD. Example: /v1/onchain/base/gas","url":"https://1gateway.dev/v1/onchain/base/gas?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","properties":{"required":{"type":"string"},"properties":{"type":"string"}}},"responseSchema":{"type":"json","example":{"rpc":{"kind":"public","source":"base-rpc.publicnode.com"},"note":"Costs use the next base fee + the standard (median 50th-percentile) tip over the last 20 blocks, plus the L1 data fee upper bound from the GasPriceOracle. Gas …","block":{"number":52774276,"timestamp":"2026-10-18T15:38:19.000Z","gasUsedPct":11.7},"chain":"base","costs":[{"label":"ETH transfer","action":"eth_transfer","l2FeeEth":1.26e-7,"totalEth":1.267e-7,"totalUsd":0.0003011,"typicalGas":21000,"l1DataFeeEth":7.056e-10}],"ethUsd":2376,"chainId":8453,"suggested":{"fast":{"maxFeePerGasGwei":0.0122,"maxPriorityFeePerGasGwei":0.0022},"slow":{"maxFeePerGasGwei":0.0105,"maxPriorityFeePerGasGwei":0.0005001},"standard":{"maxFeePerGasGwei":0.011,"maxPriorityFeePerGasGwei":0.001}},"baseFeeGwei":0.005,"recentBlocks":{"count":20,"avgGasUsedPct":8.5},"nextBaseFeeGwei":0.005,"priorityFeeGwei":{"fast":0.0022,"node":0.001,"slow":0.0005001,"standard":0.001}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_Z4Xr2CvH22a4ap2el255s","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Returns current and next Base L2 gas fees, priority fee tiers (slow/standard/fast), and estimated USD/ETH costs for common transaction types including ETH transfers, ERC-20 ops, DEX swaps, NFT mints, and contract deploys.","exampleAgentPrompt":"What are the current gas fees on Base right now — give me the slow, standard, and fast priority fee tiers, and tell me how much a DEX swap and an ERC-20 transfer would cost in USD.","exampleUseCases":[{"title":"Pre-swap gas cost check","prompt":"Before I execute this swap on Base, what's the current standard gas price and how much will the swap cost me in USD at today's ETH price?"},{"title":"Contract deployment cost estimate","prompt":"I'm about to deploy a smart contract on Base — what will it cost in ETH and USD right now using a fast gas setting, including both L2 fee and L1 data fee?"},{"title":"Optimal gas tier selection","prompt":"I need to submit a Base transaction but I'm not in a rush — what's the current slow priority fee in Gwei and what's the maxFeePerGas I should use to avoid overpaying?"}],"resultDescription":"A JSON object containing: current and next base fee in Gwei, priority fee tiers (slow/standard/fast) with maxFeePerGas and maxPriorityFeePerGas suggestions, recent block stats (number, timestamp, gas used %), average block fullness over last 20 blocks, current ETH/USD price, and itemized cost estimates (in ETH and USD, with L2 and L1 data fee breakdown) for ETH transfer, ERC-20 transfer/approve, DEX swap, NFT mint, and contract deploy.","failureModes":["RPC node temporarily unavailable — stale or missing block data","ETH/USD price feed outage — costs returned without USD values","Rate limit or payment failure — 402 response if x402 payment not processed","Network congestion causes unusually high or anomalous fee estimates"],"whenToPreferThis":"Use this endpoint when an agent needs to price or time a transaction on the Base L2 network specifically, including getting actionable gas tier recommendations and real USD cost estimates for common operation types. Prefer over generic Ethereum mainnet gas APIs when the target chain is Base (chainId 8453). Ideal before executing swaps, mints, transfers, or deployments to avoid overpaying or underpricing gas.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-28T12:36:02.388Z","isFirstParty":false,"canonicalSlug":"base-network-gas-price-transaction-cost-estimator-5e351e84"}