An allowance lets a specified spender request token movement under contract rules.
LET’S PICTURE IT
Giving a delivery service permission to collect up to five parcels differs from handing it one parcel now.
SEE IT FOR YOURSELF
Build a transfer call from typed fieldsStep 1 / 4
The standard transfer interface takes an address and a raw integer amount. This diagram uses address one and amount one hundred.
The standard transfer interface takes an address and a raw integer amount. This diagram uses address one and amount one hundred.Keccak-256 of the canonical signature supplies the first four bytes. The transfer selector is a9059cbb.An address is twenty bytes. Standard ABI encoding adds twelve zero bytes on the left to fill one thirty-two-byte word.The integer one hundred is hex 64, left-padded in word one. Selector plus two words produces sixty-eight bytes of standard calldata.
Animated local teaching model. No wallet, RPC or live blockchain data. Some labels and hashes are abbreviated for readability.
Read the spender field
An ERC-20 approve call identifies a spender and a raw allowance amount. The spender is the party permitted under the token’s implementation, not necessarily the recipient shown in a website’s purchase summary.
Permission can outlast the page
The allowance is recorded in contract state. Disconnecting a website or closing its tab does not erase that state. Changing it requires the appropriate authorized action under the token or permission mechanism.
Approval and transfer differ
A transfer directly requests token movement to a recipient. An approval changes permission for a spender. Similar-looking address-and-integer input fields can request these different actions through different function selectors.
Inspect both calls locally
Choose transfer and approve in the ABI encoder. Compare the selector while keeping the same address and amount. Nothing executes in the lab, so you can study permission encoding without connecting a wallet.