Introduction

Hi, I'm cardene, a software engineer and technical writer focused on blockchain and AI.

I've also authored Japanese technical books on specification-driven development with LLMs and decentralized application (DApp) development.

I also build and publish a variety of tools, libraries, and open-source projects.

ERC-7561 proposes a simplified NFT interface for smart contract wallets by removing several ERC-721 operations: safeTransferFrom, approve, setApprovalForAll, getApproved, and isApprovedForAll.

This article explains the proposal, with additional context and examples.

You can find my other proposal articles here.

Overview

The proposal introduces a type of NFT designed around user-controlled smart contract wallets, including account abstraction. It retains a subset of the familiar ERC-721 interface while shifting more responsibilities to the wallet.

User contract wallets and account abstraction

A smart contract wallet can support more complex operations and authorization rules than a conventional externally owned account. Account abstraction allows account behavior and key-management policies to be customized, potentially enabling stronger authentication, multiple signature requirements, and other security features.

For background on account abstraction, see:

ERC-4337: Account abstraction without protocol changes

Relationship to ERC-721

ERC-721 defines a standard interface for NFTs, which represent distinct assets identified by unique token IDs. Applications use NFTs to represent artwork, collectibles, and many other resources.

For background on ERC-721, see:

https://chaldene.net/erc721

Simplified design

ERC-7561 reduces the asset-level interface by removing:

  • approve: Authorizes another address to transfer a particular token.
  • setApprovalForAll: Grants an operator permission to manage an owner's tokens.
  • getApproved: Returns the approved address for a token.
  • isApprovedForAll: Checks operator approval.
  • safeTransferFrom: Transfers a token while checking recipient compatibility where required.

Removing these functions aims to simplify NFT contracts. Common ownership and transfer functionality remains, but this is interface overlap rather than full ERC-721 compatibility.

Ethereum traditionally distinguishes externally owned accounts (EOAs) from contract accounts.

Externally owned accounts

An EOA is controlled through a private key. Its authorized transaction signatures allow it to send ETH and invoke smart contracts. In the traditional account model described by this 2024 article, an EOA has state but no executable contract code of its own and cannot autonomously submit transactions in response to conditions.

Contract accounts

A contract account is governed by deployed smart contract code. When invoked, that code can implement conditional execution, application logic, and authorization policies. Contract accounts have state, and their behavior is determined by code rather than by an intrinsic account private key. A contract wallet may nevertheless use private-key signatures to authorize its operations.

Principal differences

Control: EOAs are directly controlled by signing keys, whereas contract accounts enforce programmed rules.

Functionality: EOAs can initiate transactions. Contracts execute when invoked; they do not autonomously initiate top-level transactions without an external trigger.

Use cases: EOAs are commonly used for basic transactions and asset custody, while contracts implement application logic and programmable account behavior.

These distinctions describe the traditional model. Later protocol developments, such as account code delegation, are outside the historical scope of this article.

Motivation

ERC-7561 revisits the responsibilities of the ERC-721 standard.

ERC-721 fundamentals

ERC-721 represents distinct assets on Ethereum. Each token has a unique identifier within its contract. The standard defines ownership and transfer-related methods, including transferFrom, approve, getApproved, setApprovalForAll, isApprovedForAll, and safeTransferFrom.

Proposed approach

The new approach aims to keep the NFT contract simple while relying on smart contract wallets for more complex behavior.

Simplifying the NFT contract

The asset-level contract retains the basic transferFrom operation for ownership changes and the ownership queries. More elaborate approval and safe-transfer functionality is removed from the proposed minimum interface.

Moving permission management to the user account

Instead of relying on token-contract operator approvals, a user's smart contract wallet can implement its own authorization policies. This can give users more flexibility over how their assets are managed.

Removing safeTransferFrom

Applications are encouraged to interact with the relevant user's contract wallet rather than directly relying on the NFT contract's operator authorization. Recipient checks and other protections must be addressed by the wallet or application where appropriate.

Forward compatibility with ERC-721

The retained methods are also found in ERC-721. Software designed around the smaller interface may therefore be able to interact with existing ERC-721 tokens, subject to their authorization rules.

The proposal aims to simplify NFT management and transfers in an environment where smart contract wallets can implement more flexible user-specific authorization. This changes where security controls are enforced rather than eliminating the need for them.

Specification

Contracts conforming to the proposal implement the following interface.

ts
pragma solidity ^0.8.20;

/**
 * @title ERC7561 Simple NFT interface 
 * @dev See https://ercs.ethereum.org/ERCS/erc-7561
 */
interface IERC7561 {
    /**
     * @notice Used to notify transfer NFT.
     * @param from Address of the from
     * @param to Address of the receive
     * @param tokenId The transaction token id 
     */
    event Transfer(
        address indexed from,
        address indexed to,
        uint256 indexed tokenId
    );

    /**
     * @notice  Count all NFTs assigned to an owner
     * @param owner Address of the owner
     * @return The number of NFTs owned by `owner`, possibly zero
     */
    function balanceOf(address owner) 
        external
        view
        returns (uint256);

    /**
     * @notice Find the owner of an NFT
     * @param tokenId The identifier for an NFT
     * @return The address of the owner of the NFT
     */
    function ownerOf(uint256 tokenId) 
        external  
        view
        returns (address);
	  

    /**
     * @notice Transfer ownership of an NFT
     * @param from Address of the from
     * @param to Address of the to
     * @param tokenId The NFT to transfer
     */
    function transferFrom(address from, address to, uint256 tokenId) external;

}

Transfer

javascript
event Transfer(
    address indexed from,
    address indexed to,
    uint256 indexed tokenId
);

Overview

An event recording a transfer of an NFT.

Details

The event is emitted when ownership changes from one address to another. Like the corresponding ERC-721 event, it uses indexed parameters to support searching and filtering blockchain logs.

Parameters

  • from: Address transferring the NFT.
  • to: Address receiving the NFT.
  • tokenId: ID of the transferred token.

balanceOf

javascript
function balanceOf(address owner) 
    external
    view
    returns (uint256);

Overview

Returns the number of NFTs held by a specified owner.

Details

The function returns the owner's token count, which is zero when the owner holds no tokens. It can be used to track NFT holdings.

Parameter

  • owner: Owner address.

Return value

  • uint256: Number of NFTs owned by the address.

ownerOf

javascript
function ownerOf(uint256 tokenId) 
    external  
    view
    returns (address);

Overview

Returns the owner of a specified NFT.

Details

The function looks up the owner address associated with an existing token ID.

Parameter

  • tokenId: NFT identifier.

Return value

  • address: Owner of the NFT.

transferFrom

javascript
function transferFrom(address from, address to, uint256 tokenId) external;

Overview

Transfers an NFT from one address to another.

Details

The function transfers ownership of the specified token. Authorization must follow the proposed owner-controlled model and the relevant wallet implementation rather than assuming the removed ERC-721 approval methods are available.

Parameters

  • from: Address transferring the NFT.
  • to: Address receiving the NFT.
  • tokenId: ID of the NFT being transferred.

Rationale

The proposal aims to simplify NFT contracts by removing approve, setApprovalForAll, getApproved, isApprovedForAll, and safeTransferFrom. The intended benefits are simpler implementations, fewer asset-level authorization features, and improved suitability for contract wallets.

Security

Removing third-party approvals from the token interface may reduce risks associated with persistent operator permissions. However, equivalent authorization may be implemented by the wallet, and removing the safe-transfer check creates other considerations. The overall security depends on both components.

Reduced complexity

A smaller interface can be easier to understand, implement, and test. Moving policy decisions to wallets can reduce repeated logic in individual NFT contracts, although it also makes wallet security and interoperability more important.

Efficiency

Removing unnecessary token-level operations may reduce some storage and execution overhead. Actual gas savings depend on the implementation and whether wallet-level authorization introduces additional execution costs.

Suitability for smart contract wallets

Smart contract wallets support programmable asset management and security policies. The simplified interface aims to integrate with these wallets while leaving complex permissions and operations to the account layer.

ERC-7561 aims to retain essential NFT functionality while simplifying the asset interface for smart contract wallet environments. Its benefits depend on the design of the surrounding wallets and applications.

Compatibility

Forward compatibility

Software using only the reduced interface may be able to interact with existing ERC-721 implementations because the retained functions also exist in ERC-721. This is the practical direction of compatibility intended by the proposal.

Backward compatibility

The reverse direction is not guaranteed. Existing ERC-721 applications may depend on functions removed by ERC-7561. A reduced-interface NFT therefore cannot automatically replace an ERC-721 token in every existing application.

The original article uses inconsistent descriptions of forward and backward compatibility. The important distinction is that ERC-721 implements the retained method subset, whereas ERC-7561 does not implement the complete ERC-721 interface.

Implementation

ts
pragma solidity ^0.8.20;

import "./IERC7561.sol";
import "../../math/SafeMath.sol";

/**
 * @title Standard ERC7561 NFT
 * @dev Note: the ERC-165 identifier for this interface is 0xc1b31357
 * @dev Implementation of the basic standard NFT.
 */
contract ERC7561 is IERC7561 {

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    mapping(uint256 tokenId => address) private _owners;

    mapping(address owner => uint256) private _balances;

    uint256 private _totalSupply;

    function totalSupply() external view returns (uint256) {
        return _totalSupply;
    }

    function balanceOf(address owner) public view  returns (uint256) {
        require (owner != address(0));
        
        return _balances[owner];
    }

    function ownerOf(uint256 tokenId) public view  returns (address) {
        return _requireOwned(tokenId);
    }


    function transferFrom(address from, address to, uint256 tokenId) public  {

        require(from == msg.sender);

        require (to != address(0) );

        address previousOwner = _update(to, tokenId);

        require(previousOwner == from);
    }


    function _ownerOf(uint256 tokenId) internal view virtual returns (address) {
        return _owners[tokenId];
    }

    function _requireOwned(uint256 tokenId) internal view returns (address) {
        address owner = _ownerOf(tokenId);
        require(owner != address(0));
            
        return owner;
    }

    function _update(address to, uint256 tokenId) internal virtual returns (address) {
        address from = _ownerOf(tokenId);

        
        // Execute the update
        if (from != address(0)) {         

            unchecked {
                _balances[from] -= 1;
            }
        }

        if (to != address(0)) {
            unchecked {
                _balances[to] += 1;
            }
        }

        _owners[tokenId] = to;

        emit Transfer(from, to, tokenId);

        return from;
    }

}

The historical implementation is reproduced unchanged. It should be checked against its dependencies, authorization requirements, and applicable compiler version before use.

Security considerations

ERC-7561 is not fully backward compatible with the existing ERC-721 standard. Applications relying on removed methods may not work directly with the proposed asset interface.

What backward compatibility means

Backward compatibility allows a new system to continue supporting existing interfaces, applications, or data. Removing required interface methods can break software built for the earlier version.

Impact of the proposal

Existing dApps may require changes if they rely on approve, operator approvals, or safeTransferFrom. Although transferFrom remains available, its authorization semantics must also be taken into account.

Applications should consider the risk of transfers to recipients that cannot subsequently manage their NFTs, and should not assume the reduced interface supports ordinary ERC-721 receiver checks.

Impact on developers

Developers may need to update or redesign integrations to support the simplified interface and contract-wallet authorization model. They should evaluate the trade-offs among reduced asset-level complexity, wallet-level security, and compatibility with existing applications.

Citation

Xiang (@wenzhenxiang), Ben77 (@ben2077), Mingshi S. (@newnewsms), "ERC-7561: Simple NFT, Simplified ERC-721 [DRAFT]," Ethereum Improvement Proposals, no. 7561, October 2023. [Online serial]. Available: https://eips.ethereum.org/EIPS/eip-7561.

Conclusion

ERC-7561 proposes a simplified NFT interface for contract wallets, removing several ERC-721 approval and safe-transfer methods while retaining basic ownership queries and transfers.

If you have questions, feel free to contact me on Twitter.

Twitter @cardene777

You can also find my work on the following sites.

https://chaldene.net/