Is 1,000,000 one token or a million?
A token transaction's raw data in a block explorer may show a large integer such as 1000000, while the wallet displays 1 USDC. ERC-20 tokens store balances as integers without decimal points and use a value called decimals to say where the decimal point goes when displayed.
This guide shows with a hypothetical table how decimals is used for display and how differently the same raw value reads across tokens with different decimals. It also covers what to watch when reading approval amounts and when meeting look-alike tokens.
Integer storage and decimals
The ERC-20 standard has token contracts return balances through functions like balanceOf, and describes decimals as returning the number of decimals the token uses. The standard marks decimals as optional and notes that it is for usability. All calculations inside the contract are in integers.
As Ethereum.org's ERC-20 page explains, wallets and apps divide the raw integer by ten to the power of decimals to show a readable amount. With decimals of 6, a raw value of 1,000,000 is one token; with 18, ten to the eighteenth is one token. Decimals changes neither value nor divisibility, only how amounts are shown.
Same raw value, different amounts
The table compares, in a hypothetical example, how a raw value of 1,000,000 displays depending on decimals.
| Token (hypothetical) | Decimals | Raw value | Displayed amount |
|---|---|---|---|
| Token A | 0 | 1,000,000 | 1,000,000 |
| Token B | 6 | 1,000,000 | 1 |
| Token C | 8 | 1,000,000 | 0.01 |
| Token D | 18 | 1,000,000 | 0.000000000001 |
The same raw value can display amounts differing by a factor of ten to the eighteenth. An app that reads decimals wrongly can show balances or amounts that are badly off.
Reading approval amounts
The amount in a token approval is also recorded as a raw integer. If a wallet shows the raw value without converting it by decimals, users struggle to judge its size. Very large raw values often mean an effectively unlimited approval.
Conversely, a screen might show 100 while the actual raw value, interpreted with the token's real decimals, is far larger than intended. For important approvals, check the raw value and the token's decimals in a block explorer and calculate the real amount yourself.
Names and symbols are not proof
An ERC-20 token's name and symbol, like decimals, are values the contract reports about itself. Anyone can deploy a contract named USDC with symbol USDC and decimals of 6. If an unfamiliar USDC appears in your wallet, verify it by contract address, not by name.
Ethereum.org's security guidance stresses caution with tokens of unknown origin and the sites they point to. Fake tokens sometimes appear in wallets under real names to lure users to phishing sites.
Many wallets now hide unrecognized tokens by default or mark them as unverified. Those labels are helpful, but they rely on the wallet's own lists, so the contract address remains the final check.
Checks when handling tokens
When receiving or approving a new token, work through these steps.
- Confirm the token's contract address matches the one in official sources.
- Look up the contract's decimals value in a block explorer.
- Divide the raw value of an approval or transfer by ten to the power of decimals to get the real amount.
- If a token with the same name exists on several networks, check each network's contract address separately.
- If a token of unknown origin arrives, do not trade it or visit sites it points to.
Differences across networks
Tokens with the same name can have different decimals on different networks. One network might issue a token with decimals of 6 while a bridged version elsewhere uses 18. When calculating amounts across networks or entering raw values into contracts, check each network's decimals.
Even if you are not a developer, comparing the amount your wallet shows with the raw value in a block explorer before a transaction is a habit that prevents costly mistakes.
In a hypothetical bridge transfer, entering a raw value of 1,000,000 intended for a token with decimals of 6 into a version with decimals of 18 would move a millionth of a millionth of a token instead of one whole token.
Before drawing conclusions
The tokens and values here are hypothetical and illustrate how display works. Real tokens differ in decimals and behavior, and some follow the standard only partly.
When checking, use the ERC-20 standard, Ethereum.org, and current block explorer data, checking how recent each one is. None of the figures here are a signal to buy or sell.