About this tool
What this converter answers
The Wei Gwei Ether Converter translates a single value across every common Ethereum unit (wei, kwei, mwei, gwei, szabo, finney, ether) using the canonical 10^18 base, with an optional ether to USD line driven by a price you supply. Use it when reading on chain transactions, writing Solidity tests, double checking a gas estimate, or sanity checking a calldata value before signing.
The converter handles every unit Solidity and Etherscan still expose, holds the canonical wei amount as a BigInt, and never quietly truncates large numbers the way a floating point converter would. Decimal entries up to 18 places round trip without drift, and the Share button gives you a URL that reproduces the exact scenario in another browser.
How to use it
Click into any row that matches the unit you have. The value updates instantly across every other row, so you can paste 20 into the gwei row and read the equivalent in wei, ether, or finney without leaving the page. The active row gets an indigo highlight so you always know which input is the source of truth.
For an ether to USD conversion, paste a price into the optional USD field at the bottom. Common sources are Coinbase, Kraken, CoinGecko, or your own oracle feed. The multiplication runs locally so the price you trust is the price you get. Use the Reset button to return to one ether, and the Share scenario button to copy a URL that preserves the value, the active unit, and the price.
What goes into the math
Every conversion routes through viem.parseUnits and viem.formatUnits. Decimal shifts are wei 0, kwei 3, mwei 6, gwei 9, szabo 12, finney 15, ether 18. The tool stores the canonical amount as a single BigInt of wei, so a value of 1 ether equals 1,000,000,000,000,000,000n internally and round trips to every other unit with zero loss.
The ether to USD figure is a plain multiplication: ether amount times the price you entered, formatted with two decimal places. Nothing else happens. There is no fetch, no oracle, no rounding heuristic.
Where the answer usually breaks down
The number one trap is using a calculator that converts through JavaScript floats. One ether is 10^18 wei, which sits well past the safe integer range. A float based converter silently rounds the trailing digits and gives you a wrong wei value for any nontrivial amount. This converter avoids that by holding the canonical value in a BigInt the entire time.
The second trap is mixing up gwei and wei when reading gas math. A 20 gwei priority fee is 20,000,000,000 wei, not 20 wei. Etherscan, MetaMask, and Foundry all default to gwei for gas, so a paste from one tool into another that expects wei looks correct but is off by a factor of a billion. When in doubt, drop the value into this converter and confirm both rows.
When the answer is real and when it is not
The unit conversion is exact. There is no approximation. If you put 1 ether in, you get 10^18 wei out, every time. The same is true for any decimal up to 18 places. Use this for production gas math, audit reports, signing flows, and anywhere you need a number you can defend.
The ether to USD line is only as real as the price you entered. ETH prices move every second; a stale quote in a report is misleading. Always paste a dated price from the exchange or oracle you trust, and write the timestamp next to the figure when you export it.
How this differs from vendor calculators
This converter is vendor neutral. The math is BigInt all the way through. Every unit appears in one column instead of being hidden behind a dropdown. There is no signup, no analytics, no rate limit, and no remembered state on a server. The shareable URL hash means you can hand a colleague a link and they get the exact same numbers without an account or a screenshot.
Sources used for the unit definitions and decimal shifts include the official ethereum.org denominations reference, the go-ethereum denomination constants, and the Solidity ether units page.
Designing a contract that depends on careful unit math?
Off by a factor of 10^9 in gas math, fee splits, or oracle scaling is the kind of bug that costs real ether. Bring your design for a focused review.
Book a smart contract reviewFrequently asked questions
- What is wei and why does Ethereum use it?
- Wei is the smallest denomination of ether. One ether equals exactly 10^18 wei. Ethereum quotes balances and gas math in wei because integer arithmetic on a fixed base avoids the rounding errors that plague floating point money. Solidity, the JSON RPC, and every block explorer ultimately store values as wei and only format them up for humans.
- How do I convert gwei to ether?
- Divide the gwei value by 10^9. The converter does this for you with full BigInt precision, but the math is simple: 1 gwei equals 0.000000001 ether, and 1 ether equals 1,000,000,000 gwei. Gas prices on Etherscan are usually quoted in gwei because typical priority fees of 1 to 50 gwei would otherwise look like long strings of leading zeros in ether.
- Why use BigInt instead of regular JavaScript numbers?
- JavaScript numbers are 64 bit floats and lose precision above 2^53. One ether is 10^18 wei, which sits well past that limit. Converting through floats silently rounds the last few digits and produces wrong wei values for any nontrivial amount. The tool uses native BigInt through viem.parseUnits and viem.formatUnits, so a wei value round trips exactly across every unit.
- What are szabo and finney?
- Szabo and finney are intermediate ether denominations named after early cryptographers. One szabo equals 10^12 wei (a microether). One finney equals 10^15 wei (a milliether). Modern Solidity removed the szabo and finney keywords in version 0.7, but the units still appear in legacy contracts, audit reports, and Etherscan unit dropdowns, which is why this converter keeps them.
- Does this tool support ether to USD conversion?
- Yes, but only with a price you supply. There is no live feed because that would require a backend. Paste the ETH price you trust into the optional field and the USD line updates locally. For pricing during an audit or report, prefer a dated quote from Coinbase, Kraken, or CoinGecko over a generic widget so the assumption is reproducible.
- Can I share my converter result with a teammate?
- Yes. The tool encodes your value, unit, and USD price into the URL hash on every change. The Share scenario button copies the full URL to your clipboard. Open it in another browser or hand it to a teammate and the same numbers reappear without any account or saved state. The hash never reaches the server.
- How does this differ from Etherscan or Alchemy converters?
- Etherscan and Alchemy give you the same conversions but with vendor branding and tracking. This converter is open source code paths, BigInt precision throughout, no login or analytics, and a shareable URL hash. The math is identical because both implementations use the canonical 10^18 base; the difference is the trust and shareability surface around it.
Related services and reading
Follow the cluster from a simple unit conversion into deeper Ethereum work.