ERC-721 function
safeTransferFrom(address,address,uint256,bytes)
Transfers an ERC-721 token safely while forwarding arbitrary data to the recipient.
- Selector
- 0xb88d4fde
- Mutability
- nonpayable
Generate safeTransferFrom calldata
Edit the example inputs to rebuild the bytes instantly in your browser. Nothing is sent and no transaction is submitted.
address
address
uint256
bytes
calldata164 bytes
sel0xb88d4fde
safeTransferFrom(address,address,uint256,bytes)
0x000000000000000000000000001111111111111111111111111111111111111111
from · address =0x11111111…111111
0x200000000000000000000000002222222222222222222222222222222222222222
to · address =0x22222222…222222
0x40000000000000000000000000000000000000000000000000000000000000002a
tokenId · uint256 =42
0x600000000000000000000000000000000000000000000000000000000000000080
→ data, points to0x80
0x800000000000000000000000000000000000000000000000000000000000000000
data · length =0 bytes
How safeTransferFrom works
This overload performs the same receiver check as the three-argument form and passes data to onERC721Received without assigning a standard meaning to it.
Parameters
| Name | Solidity type | Meaning |
|---|---|---|
| from | address | Current owner of the NFT. |
| to | address | New owner or receiving contract. |
| tokenId | uint256 | NFT to transfer. |
| data | bytes | Optional application-specific bytes forwarded to a contract recipient. |