{
  "$schema": "https://degreesofsatoshi.com/encyclopedia/schemas/article-v1.json",
  "schemaVersion": "1.0.0",
  "id": "erc-20-tokens",
  "canonical": "https://degreesofsatoshi.com/encyclopedia/erc-20-tokens/",
  "collection": "ethereum",
  "title": "ERC-20 tokens: balances, decimals and spending permissions",
  "description": "Understand the ERC-20 token interface through a balance and decimals example, including allowances and what the standard does not say about value.",
  "aliases": [
    "ERC20",
    "fungible token",
    "token decimals"
  ],
  "dates": {
    "published": "2026-10-02",
    "modified": "2026-10-02",
    "verified": "2026-10-02T18:16:35.976Z",
    "dataAsOf": null
  },
  "authorship": {
    "publisher": "Degrees of Satoshi editorial project",
    "process": "AI-assisted research and drafting with a separate automated source-verification pass; no external expert or named human review is implied."
  },
  "quickAnswer": {
    "text": "ERC-20 is a standard interface for fungible tokens implemented by smart contracts. It defines ways to inspect supply and balances, transfer units and authorize a spender. It does not guarantee a token’s value, backing, uniqueness of name or absence of issuer controls. ETH itself is Ethereum’s native asset, not an ERC-20 balance.",
    "claimId": "erc-20-tokens-quick-answer",
    "sourceIds": [
      "erc20",
      "ether"
    ]
  },
  "keyFacts": [
    {
      "label": "Balance query",
      "value": "balanceOf reads units held by an account",
      "sourceIds": [
        "erc20"
      ],
      "id": "balance-query",
      "claimId": "erc-20-tokens-fact-balance-query"
    },
    {
      "label": "Decimals",
      "value": "Optional display metadata; units remain integers",
      "sourceIds": [
        "erc20"
      ],
      "id": "decimals",
      "claimId": "erc-20-tokens-fact-decimals"
    },
    {
      "label": "Allowance",
      "value": "A limit on an approved spender’s transfers",
      "sourceIds": [
        "erc20"
      ],
      "id": "allowance",
      "claimId": "erc-20-tokens-fact-allowance"
    }
  ],
  "prerequisites": [
    "ethereum-smart-contracts",
    "ether-and-ethereum"
  ],
  "sections": [
    {
      "id": "shared-interface",
      "heading": "A common interface lets different tokens work with the same tools",
      "sourceIds": [
        "erc20",
        "interacting"
      ],
      "paragraphs": [
        "Wallets and applications can call familiar functions such as balanceOf and transfer without inventing a new interface for every token. Fungible means units of a particular token are treated as interchangeable within that token’s accounting.",
        "The interface does not make two unrelated tokens interchangeable. Matching symbols or decimals do not make their balances part of the same asset. Network and contract identity are essential context."
      ]
    },
    {
      "id": "decimals-example",
      "heading": "Convert the integer with the token’s own scale",
      "sourceIds": [
        "edition-erc20"
      ],
      "paragraphs": [
        "For a token displaying six decimals, 1,250,000 base units display as 1.25 tokens. With eighteen decimals, the same raw integer represents a very different quantity. The decimals field changes display interpretation, not the integer stored or transferred.",
        "ERC-20 makes metadata such as decimals optional. Software needs an explicit supported convention if metadata is missing, and should not assume every Ethereum token uses eighteen decimals. Preserve integer precision when encoding amounts."
      ]
    },
    {
      "id": "permission-flow",
      "heading": "Approving a spender enables a separate transfer path",
      "sourceIds": [
        "erc20",
        "gas"
      ],
      "paragraphs": [
        "A user can transfer their own tokens or approve another spender to use transferFrom within an allowance. This supports applications that need to move tokens as one step in a larger operation.",
        "For example, approving 20 units permits spending up to that authorized amount under the token’s implementation. It does not by itself purchase anything. An included approval transaction can have an ETH gas cost even though the token balance has not moved."
      ]
    },
    {
      "id": "standard-boundary",
      "heading": "The interface is not a promise about backing or control",
      "sourceIds": [
        "erc20",
        "contracts"
      ],
      "paragraphs": [
        "ERC-20 specifies token operations, not a reserve requirement, a guaranteed market price or a universal supply schedule. Extra contract logic may determine minting, transfer restrictions or administrative powers.",
        "A successful token transfer is evidence that the contract accepted the operation. Assessing an issuer’s claims or the rights attached to a token requires additional evidence outside the interface specification."
      ]
    }
  ],
  "faq": [
    {
      "question": "Is ETH an ERC-20 token?",
      "answer": "No. ETH is the native asset tracked by Ethereum accounts. An ERC-20 token maintains its balances through a contract interface.",
      "sourceIds": [
        "ether",
        "erc20"
      ]
    },
    {
      "question": "Does a token ticker uniquely identify a token?",
      "answer": "No. ERC-20 permits display names and symbols but does not provide a global unique-name registry. The chain and contract identify the implementation.",
      "sourceIds": [
        "erc20"
      ]
    },
    {
      "question": "Can a standard token transfer report failure?",
      "answer": "Yes. ERC-20 instructs callers to handle a false return value rather than assuming every transfer succeeds. Actual implementations require careful handling.",
      "sourceIds": [
        "erc20"
      ]
    }
  ],
  "claims": [
    {
      "id": "erc-20-tokens-quick-answer",
      "articleSlug": "erc-20-tokens",
      "statement": "ERC-20 is a standard interface for fungible tokens implemented by smart contracts. It defines ways to inspect supply and balances, transfer units and authorize a spender. It does not guarantee a token’s value, backing, uniqueness of name or absence of issuer controls. ETH itself is Ethereum’s native asset, not an ERC-20 balance.",
      "sourceIds": [
        "source-e99ee03961c5d3e7",
        "source-92cb5bbc68517168"
      ],
      "sourceLocators": [
        {
          "sourceId": "source-e99ee03961c5d3e7",
          "locator": "Methods: decimals, balanceOf, transfer, approve, transferFrom, allowance"
        },
        {
          "sourceId": "source-92cb5bbc68517168",
          "locator": "What is ether; denominations; transferring ether"
        }
      ],
      "scope": {
        "collection": "ethereum",
        "dataAsOf": null,
        "blockHeight": null
      },
      "qualification": "",
      "evidenceStatus": "documented",
      "verification": {
        "status": "verified",
        "method": "independent automated source review",
        "checkedAt": "2026-10-02T18:16:35.976Z",
        "reviewer": "Codex independent automated reviewer /root/verify_ethereum_100",
        "notes": [
          "Read ERC-20 decimals OPTIONAL requirement and uint256 transfer/balance methods. Recomputed 1250000/10^6 = 1.25 and contrasted with 1250000/10^18 = 0.00000000000125.",
          "Metadata changes display scaling, not base-unit integer amounts; missing decimals requires a supported convention rather than an automatic eighteen-decimal assumption."
        ]
      }
    },
    {
      "id": "erc-20-tokens-fact-balance-query",
      "articleSlug": "erc-20-tokens",
      "statement": "Balance query: balanceOf reads units held by an account",
      "sourceIds": [
        "source-e99ee03961c5d3e7"
      ],
      "sourceLocators": [
        {
          "sourceId": "source-e99ee03961c5d3e7",
          "locator": "Methods: decimals, balanceOf, transfer, approve, transferFrom, allowance"
        }
      ],
      "scope": {
        "collection": "ethereum",
        "dataAsOf": null,
        "blockHeight": null
      },
      "qualification": "",
      "evidenceStatus": "documented",
      "verification": {
        "status": "verified",
        "method": "independent automated source review",
        "checkedAt": "2026-10-02T18:16:35.976Z",
        "reviewer": "Codex independent automated reviewer /root/verify_ethereum_100",
        "notes": [
          "Read ERC-20 decimals OPTIONAL requirement and uint256 transfer/balance methods. Recomputed 1250000/10^6 = 1.25 and contrasted with 1250000/10^18 = 0.00000000000125.",
          "Metadata changes display scaling, not base-unit integer amounts; missing decimals requires a supported convention rather than an automatic eighteen-decimal assumption."
        ]
      }
    },
    {
      "id": "erc-20-tokens-fact-decimals",
      "articleSlug": "erc-20-tokens",
      "statement": "Decimals: Optional display metadata; units remain integers",
      "sourceIds": [
        "source-e99ee03961c5d3e7"
      ],
      "sourceLocators": [
        {
          "sourceId": "source-e99ee03961c5d3e7",
          "locator": "Methods: decimals, balanceOf, transfer, approve, transferFrom, allowance"
        }
      ],
      "scope": {
        "collection": "ethereum",
        "dataAsOf": null,
        "blockHeight": null
      },
      "qualification": "",
      "evidenceStatus": "documented",
      "verification": {
        "status": "verified",
        "method": "independent automated source review",
        "checkedAt": "2026-10-02T18:16:35.976Z",
        "reviewer": "Codex independent automated reviewer /root/verify_ethereum_100",
        "notes": [
          "Read ERC-20 decimals OPTIONAL requirement and uint256 transfer/balance methods. Recomputed 1250000/10^6 = 1.25 and contrasted with 1250000/10^18 = 0.00000000000125.",
          "Metadata changes display scaling, not base-unit integer amounts; missing decimals requires a supported convention rather than an automatic eighteen-decimal assumption."
        ]
      }
    },
    {
      "id": "erc-20-tokens-fact-allowance",
      "articleSlug": "erc-20-tokens",
      "statement": "Allowance: A limit on an approved spender’s transfers",
      "sourceIds": [
        "source-e99ee03961c5d3e7"
      ],
      "sourceLocators": [
        {
          "sourceId": "source-e99ee03961c5d3e7",
          "locator": "Methods: decimals, balanceOf, transfer, approve, transferFrom, allowance"
        }
      ],
      "scope": {
        "collection": "ethereum",
        "dataAsOf": null,
        "blockHeight": null
      },
      "qualification": "",
      "evidenceStatus": "documented",
      "verification": {
        "status": "verified",
        "method": "independent automated source review",
        "checkedAt": "2026-10-02T18:16:35.976Z",
        "reviewer": "Codex independent automated reviewer /root/verify_ethereum_100",
        "notes": [
          "Read ERC-20 decimals OPTIONAL requirement and uint256 transfer/balance methods. Recomputed 1250000/10^6 = 1.25 and contrasted with 1250000/10^18 = 0.00000000000125.",
          "Metadata changes display scaling, not base-unit integer amounts; missing decimals requires a supported convention rather than an automatic eighteen-decimal assumption."
        ]
      }
    }
  ],
  "sources": [
    {
      "id": "erc20",
      "label": "ERC-20: Token Standard",
      "publisher": "Ethereum Request for Comments",
      "url": "https://raw.githubusercontent.com/ethereum/ERCs/583335b7912e51b1ea515bb662532dd29b27e786/ERCS/erc-20.md",
      "canonicalUrl": "https://eips.ethereum.org/EIPS/eip-20",
      "version": "583335b7912e51b1ea515bb662532dd29b27e786",
      "checkedAt": "2026-10-02T14:35:55.037727+00:00",
      "locator": "Methods: decimals, balanceOf, transfer, approve, transferFrom, allowance",
      "sha256": "50d0bdc535ed8987ac5c124cb5f9c39606806c97e909aae66ef4b747dd9c93dd",
      "note": "Defines fungible token balances, optional display metadata and spending allowance behavior.",
      "recordId": "source-e99ee03961c5d3e7",
      "contentSha256": "50d0bdc535ed8987ac5c124cb5f9c39606806c97e909aae66ef4b747dd9c93dd"
    },
    {
      "id": "ether",
      "label": "Introduction to ether",
      "publisher": "ethereum.org contributors",
      "url": "https://raw.githubusercontent.com/ethereum/ethereum-org-website/dcc900ff125891da5b6c723b905a7113cf1bd864/public/content/developers/docs/intro-to-ether/index.md",
      "canonicalUrl": "https://ethereum.org/en/developers/docs/intro-to-ether/",
      "version": "dcc900ff125891da5b6c723b905a7113cf1bd864",
      "checkedAt": "2026-10-02T14:42:49.460408+00:00",
      "locator": "What is ether; denominations; transferring ether",
      "sha256": "9fb80f16e8729c15f32ff263defc77bf27be0f495014d72072746259526666be",
      "note": "Defines ETH, wei and gwei, the transaction value field and the role of ETH in fees and staking.",
      "recordId": "source-92cb5bbc68517168",
      "contentSha256": "9fb80f16e8729c15f32ff263defc77bf27be0f495014d72072746259526666be"
    },
    {
      "id": "interacting",
      "label": "Interacting with smart contracts",
      "publisher": "ethereum.org contributors",
      "url": "https://raw.githubusercontent.com/ethereum/ethereum-org-website/dcc900ff125891da5b6c723b905a7113cf1bd864/public/content/developers/docs/smart-contracts/interacting/index.md",
      "canonicalUrl": "https://ethereum.org/en/developers/docs/smart-contracts/interacting/",
      "version": "dcc900ff125891da5b6c723b905a7113cf1bd864",
      "checkedAt": "2026-10-02T14:35:40.398262+00:00",
      "locator": "Reading; writing; understanding contract ABIs; events and logs; simulating",
      "sha256": "0c969a8627399edfcae7e30d5fa1fcc02218265808be25f52a9a9a46da7dc29f",
      "note": "Supports read-only calls, state-changing transactions, ABI decoding and limits of simulation.",
      "recordId": "source-64ab603c23f79017",
      "contentSha256": "0c969a8627399edfcae7e30d5fa1fcc02218265808be25f52a9a9a46da7dc29f"
    },
    {
      "id": "gas",
      "label": "Gas and fees",
      "publisher": "ethereum.org contributors",
      "url": "https://raw.githubusercontent.com/ethereum/ethereum-org-website/dcc900ff125891da5b6c723b905a7113cf1bd864/public/content/developers/docs/gas/index.md",
      "canonicalUrl": "https://ethereum.org/en/developers/docs/gas/",
      "version": "dcc900ff125891da5b6c723b905a7113cf1bd864",
      "checkedAt": "2026-10-02T14:35:40.393022+00:00",
      "locator": "How are gas fees calculated; base fee; gas limit",
      "sha256": "5af7b13e15072d45f38e6fd48e414324c7229b6110d6f8f7fc14100e5153509d",
      "note": "Supports gas units, ETH/gwei units, base/priority fees, resource limits and charges for executed failed transactions.",
      "recordId": "source-a8f47d83f0f10a68",
      "contentSha256": "5af7b13e15072d45f38e6fd48e414324c7229b6110d6f8f7fc14100e5153509d"
    },
    {
      "id": "contracts",
      "label": "Introduction to smart contracts",
      "publisher": "ethereum.org contributors",
      "url": "https://raw.githubusercontent.com/ethereum/ethereum-org-website/dcc900ff125891da5b6c723b905a7113cf1bd864/public/content/developers/docs/smart-contracts/index.md",
      "canonicalUrl": "https://ethereum.org/en/developers/docs/smart-contracts/",
      "version": "dcc900ff125891da5b6c723b905a7113cf1bd864",
      "checkedAt": "2026-10-02T14:35:40.398357+00:00",
      "locator": "What is a smart contract; a digital vending machine; limitations; multisig",
      "sha256": "e0933f91c6c58d30c1f5f05cac3c45529bf34dcb0711bbaa9a4dfe2b9b9946db",
      "note": "Supports contract code/state, deterministic rules, illustrative vending logic, external-data limits and multisignature access.",
      "recordId": "source-1bffcf35253de959",
      "contentSha256": "e0933f91c6c58d30c1f5f05cac3c45529bf34dcb0711bbaa9a4dfe2b9b9946db"
    },
    {
      "id": "edition-erc20",
      "label": "ERC-20 Token Standard",
      "publisher": "Ethereum Improvement Proposals",
      "url": "https://eips.ethereum.org/EIPS/eip-20",
      "locator": "totalSupply; balanceOf; transfer; decimals; approve; allowance; transferFrom; Transfer",
      "note": "Token supply, displayed units and balance accounting.",
      "version": "ERC-20",
      "checkedAt": "2026-10-02T17:03:45.826Z",
      "contentSha256": "98bda5e4707841a68684879878c4c165fdaa47d89ed69ebf232ab9be06ff050e",
      "recordId": "source-ac4ad503a55127bb"
    }
  ],
  "related": {
    "articles": [
      "ethereum-token-approvals",
      "erc-721-nfts",
      "erc-1155-multi-tokens"
    ],
    "dossiers": [],
    "wallets": []
  },
  "revisionHistory": [
    {
      "date": "2026-10-02",
      "kind": "published",
      "summary": "First publication after primary-source research and independent automated verification."
    },
    {
      "date": "2026-10-02",
      "kind": "substantive-edit",
      "summary": "Expanded explanation: Convert the integer with the token’s own scale. Worked examples are illustrative; source checks and independent verification are recorded separately."
    }
  ],
  "citation": "Degrees of Satoshi editorial project. “ERC-20 tokens: balances, decimals and spending permissions.” Published 2026-10-02; updated 2026-10-02. https://degreesofsatoshi.com/encyclopedia/erc-20-tokens/"
}
