Why Ether Has 18 Decimals: Gas Economics in 5 Minutes
1 Ether = 1 billion Gwei = 1 quintillion Wei. Why Ethereum needs five units for the same currency, how a transaction is actually priced — and why your calculator lies about it.
The euro has two decimal places; ether has eighteen. That is not a quirk — it is what lets a world computer settle fractions of a cent. Once you see how Wei, Gwei, and Ether fit together, you read every transaction differently — and understand why micropayments for AI agents become possible at all.
To follow along, there is the ETH Unit Converter: Wei, Gwei, and Ether converted exactly, no rounding errors, entirely in your browser.
Five names for the same currency
Ethereum computes internally only in the smallest unit — Wei. The other four are pure convenience, with fixed factors:
| Unit | In Wei | Used for |
|---|---|---|
| Wei | 1 | Machine level, exact settlement |
| Gwei | 1,000,000,000 (10⁹) | Gas prices — what you set per transaction |
| Szabo | 1,000,000,000,000 (10¹²) | Microether, historic tier (named after Nick Szabo) |
| Finney | 1,000,000,000,000,000 (10¹⁵) | Milliether, historic tier (named after Hal Finney) |
| Ether | 1,000,000,000,000,000,000 (10¹⁸) | Human amounts, exchanges, balances |
1 Ether = 1 billion Gwei = 1 quintillion Wei. The analogy: Wei is the cent, Gwei the banknote, Ether the fortune — except the "cent" here sits 18 places from the whole, because on Ethereum even millionths of a cent still buy real compute.
One transaction, worked through
Every Ethereum transaction costs gas used × gas price. The standard example: a simple transfer uses 21,000 gas. At a gas price of 21 Gwei:
21,000 × 21 Gwei = 441,000 Gwei = 0.000441 Ether
Three observations: first, the price is never quoted in Ether but in Gwei — the fee unit. Second, the result is more awkward than it looks — 0.000441 ETH, six places, and complex DeFi transactions at 200,000+ gas quickly reach amounts nobody computes in their head. Third: this is exactly where the expensive mistakes happen — confuse Gwei with Ether and you pay a billion times over. The ETH Unit Converter exists so that mistake never happens.
Since EIP-1559 (2021), the gas price itself has two parts: the base fee, which adjusts automatically with network congestion and gets destroyed ("burned"), plus the priority fee (tip) to the validator for preferred inclusion. It changes nothing about conversion — Gwei stays Gwei — but it explains why fees breathe.
Why your calculator lies
0.1 + 0.2 = 0.30000000000000004 — in JavaScript, Python, almost everywhere. Floating-point numbers round binary fractions, and at 18 decimals rounding quickly becomes money: a fraction of a cent, misrounded a thousand times across a thousand transactions, is a real loss.
That is why serious crypto software never computes with decimals but with integers in the smallest unit — and why the ETH Unit Converter uses BigInt instead of float: exact, no rounding, down to the last Wei. Rule of thumb for anyone programming with amounts: decimals are display, integers are truth.
What this has to do with AI agents
Remember the 31 cents from What Actually Happens When AI Agents Start Paying for Themselves? The average x402 transaction sits around $0.31 — an amount where classic card fees with their 30-cent fixed fee eat almost all of it. On the Ethereum side, the counterpart is granularity: an agent paying a fraction of a cent per API call needs units so small they are nearly worthless individually — and exact in aggregate. 18 decimals are the technical answer to an economic question, the same one What an AI Agent Actually Costs asks from the margin side.
Try it
The ETH Unit Converter converts all five units live — type in one field, the rest follows, shareable via deep-links like ?value=21&unit=gwei. There is a gas table and FAQ there too. And if you want to understand where the addresses you're computing with come from: How a Wallet Actually Works explains seeds and derivation paths.
For anything beyond that — custody concepts, payment flows, technical reviews — the rule stays: understand first, then test, and for real amounts have a conversation before money moves.
Sources:
Protocol & units
- Ethereum.org: Ether (ETH) — Wei, Gwei, Ether and denominations
- Ethereum.org: Gas and fees — gas usage, base fee, priority fee (EIP-1559)