Free online tools to generate, calculate,
convert, format, encode, and play.
 

ERC-20 Token Unit Converter

Convert between raw on-chain token amounts and human-readable values for any ERC-20 token decimal count.


Token Presets

Convert

The token's decimal count (0–77)
e.g. 1.5 tokens
Raw on-chain integer value

Quick Examples


How It Works

ERC-20 tokens on Ethereum and compatible blockchains store balances as unsigned integers. The decimals() function on the token contract specifies how many digits represent the fractional part. For example, a token with 6 decimals stores 1.5 tokens as 1500000 on-chain.

The formula is straightforward:

  • Human → Raw: raw = human × 10decimals
  • Raw → Human: human = raw ÷ 10decimals

Common Token Decimals

Token Decimals 1 Token (Raw)
ETH / DAI / LINK181,000,000,000,000,000,000
USDC / USDT61,000,000
WBTC8100,000,000
SUI91,000,000,000
GNO181,000,000,000,000,000,000

Why Does This Matter?

  • Smart Contracts — Solidity has no native floating-point type. All token amounts are integers scaled by 10decimals.
  • Precision — Using integers avoids floating-point rounding errors that could cause incorrect balances.
  • Interoperability — Wallets, block explorers, and dApps all need to agree on the decimal count to display correct balances.


Feedback

Help us improve this page by providing feedback, and include your name/email if you want us to reach back. Thank you in advance.


Share with