2

When Ethereum burns ether by taking it out of circulation, what exactly happens? Where does this ether go?

4 Answers 4

2

It simply disappears. It's a bit similar to burning fiat money, literally: if you burn a $10 bill properly, there's nothing of value left and that amount of value is taken out of circulation.

Technically it's just decreasing some numbers. So if the amount of Ether in circulation is X, after burning Y amount of Ether there's X - Y amount in circulation anymore.

2

Burnt tokens generally go to the zero account: 0x0000000000000000000000000000000000000000. This is the null address.

If you look at the 'from' field in newly minted tokens and contracts, it's also the zero account. It's not a real address

6
  • Do they always go to that address or only sometimes? It makes me think that the address you mention is a good proxy for the amount of ether burnt since Ethereum was launched. Sep 3, 2022 at 14:19
  • I've only ever seen ERC-20's burnt by being sent to the zero account. Maybe the EIP that made ether deflationary does it differently.
    – Ryan Sea
    Sep 3, 2022 at 18:28
  • 1
    This is a real address, just like any other address :-) For convenience it's used as a burn address, but there's a non-zero chance of generating the associated private key - there's nothing in the spec to prevent this. Using this as the 'from' address for newly minted tokens is again just a convention that seems to have been used by the community. (Chain explorers like Etherscan just listen for events, and the convention is to use 0 as the from address when emitting the mint() event.) Sep 6, 2022 at 12:09
  • "there's a non-zero chance of generating the associated private key" That is absolutely wild. There's got to be many bots attempting this
    – Ryan Sea
    Sep 6, 2022 at 21:57
  • 1
    I wouldn't say "burnt tokens generally go to the zero account". If the burning of tokens is built-in (properly), burning does not send anything to the zero but only reduces numbers. Same goes for Ethers. The zero address 'burning' is only used if the token doesn't support real burning. Sep 20, 2022 at 5:18
1

Burned tokens are just subtracted from total amount of tokens i.e from _totalSupply.

You can check openzeppelin github

Burning is done as:

    _balances[account] = accountBalance - amount; 
    // account -> who want to burn
    // amount -> How much to burn
    _totalSupply -= amount;

_burn function:

function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        uint256 accountBalance = _balances[account];
        require(accountBalance >= amount, "ERC20: burn amount exceeds balance");
        unchecked {
            _balances[account] = accountBalance - amount;
            // Overflow not possible: amount <= accountBalance <= totalSupply.
            _totalSupply -= amount;
        }

        emit Transfer(account, address(0), amount);

        _afterTokenTransfer(account, address(0), amount);
    }
2
  • Who runs this code? Sep 3, 2022 at 14:13
  • Whoever want to burn ether, Sep 11, 2022 at 6:34
1

burnt tokens are actually sent to an account address or contract address that cannot be retrieved again.

Openzeppeling/ ERC20Burnable.sol

/**
 * @dev Extension of {ERC20} that allows token holders to destroy both their own
 * tokens and those that they have an allowance for, in a way that can be
 * recognized off-chain (via event analysis).
 */
abstract contract ERC20Burnable is Context, ERC20 {
    /**
     * @dev Destroys `amount` tokens from the caller.
     *
     * See {ERC20-_burn}.
     */
    function burn(uint256 amount) public virtual {
        _burn(_msgSender(), amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, deducting from the caller's
     * allowance.
     *
     * See {ERC20-_burn} and {ERC20-allowance}.
     *
     * Requirements:
     *
     * - the caller must have allowance for ``accounts``'s tokens of at least
     * `amount`.
     */
    function burnFrom(address account, uint256 amount) public virtual {
        _spendAllowance(account, _msgSender(), amount);
        _burn(account, amount);
    }
}

This will call ERC20._burn

function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        uint256 accountBalance = _balances[account];
        require(accountBalance >= amount, "ERC20: burn amount exceeds balance");
        unchecked {
            _balances[account] = accountBalance - amount;
            // Overflow not possible: amount <= accountBalance <= totalSupply.
            _totalSupply -= amount;
        }

        emit Transfer(account, address(0), amount);

        _afterTokenTransfer(account, address(0), amount);
    }
     

_burn function just updates the state of account balance and total supply of the ERC20 token. this is what burning is just updating state balances.

Ethereum burning mechanism gets updated bu EIP proposals. I believe latest was eip-1559. With this network fees are burnt. So all other crypto platform's when they have a transaction part of the transaction fee is burnt. Their wallets automatically burn

enter image description here

You can monitor burning here: https://etherchain.org/burn

6
  • Does this mean that losing private keys for a wallet with ether will have the same impact on ether’s circulating supply as burning ether through the code mentioned above? Sep 3, 2022 at 14:16
  • Yes, Correct. It is kinda an unintentional burn
    – Yilmaz
    Sep 3, 2022 at 14:18
  • Another question. I understand what the code is doing. But I don’t know when or who runs this code? Is it the Ethereum protocol running the above, each individual wallet, or who exactly? Sorry. I am not familiar with Open Zeppelin. Sep 3, 2022 at 14:21
  • Openzeppeling just provides contracts. let's say there is AXC token. whenever they want to burn they call that _burn function. If you have 100 AXC, you call that contract's burn with amount=10, you will be burning 10 AXC
    – Yilmaz
    Sep 3, 2022 at 14:24
  • thank you for the additional details. But who then calls that function in the case of Ethereum ? Sep 3, 2022 at 14:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.