Share your GetBlock experience with other devs and get 5M RPCs

banner image

What is ERC-404? A Guide to Semi-Fungible Tokens | GetBlock.io

Deen Newman

Deen Newman

May 3, 2024

6 min read

article cover

Imagine owning a part of a unique digital artwork, yet being able to trade pieces of your ownership just like any currency. A promising new token standard for Ethereum, ERC-404, introduces this capability, shifting the perception of not only semi-fungible assets but also liquid NFTs.

What is ERC 404 all about and why both traders and developers should keep an eye on its development? Explore with us.

Tl; DR:
Combining existing ERC, Ethereum standards, the ERC-404 protocol offers NFTs that can be infinitely divisible. Holders can get instant liquidity by selling fractions or gather pieces into an NFT to sell as a traditional digital asset. While the Pandora project is leading a push to have an official standard formulated, it has yet to be properly peer-reviewed or adopted in the Ethereum ecosystem.

What is ERC 404?

ERC-404 is the recently introduced standard for tokens that cleverly blends the traits of ERC-20 with NFTs aiming to have the upsides of both.

While the concept may sound familiar as it was in a way already implemented in ERC-1155, the new approach suggests dividing NFTs into smaller parts represented by fungible tokens — a step in a way to make digital assets highly liquid.

The genesis of the new ERC for Ethereum traces back to an experiment merging ERC-20 and ERC-721 contracts. The development was advanced by the Pandora project team, who enhanced it into a comprehensive protocol.

Since the Pandora token’s launch in February 2024, the list of ERC 404 tokens has been expanding rapidly, highlighting a growing interest and belief in its potential.

ERC 404: Key Features

At its core, ERC-404 tokens are shape shifters that can automatically transition between ERC-20 and ERC-721. Let's spotlight the key characteristics enabling this:

  • Fractionalization: The standard describes an NFT divisible into smaller parts. Once a holder gathers enough pieces to complete a full token, the smart contract triggers the minting of an ERC-721 token of a random rarity;
  • Immediate liquidity: These fractions behave like any other regular cryptocurrency (ERC-20) and can be freely traded on exchanges;
  • Supply management: Should the ERC-404 tokens balance drop below one (e.g. 0.7), the corresponding NFT is burned, ensuring the proper balance;
  • Smart contract automated: Mints and burns are executed based on wallet balance without manual intervention.
ERC404_protocol_logic

Ultimately, holders can list these tokens on marketplaces and sell them as NFTs or burn them in exchange for fungible tokens to independently trade on exchanges.

How ERC-404 Differs From Other ERC Standards

ERC-404 offers a flexible experience that contrasts sharply with traditional ERC-20 or NFT tokens, which are either entirely fungible or unique.

ERC404 vs ERC721

The traditional NFT standard can also be represented by smaller fractions, or rather shares, allowing multiple investors to collectively own them. However, these fractions are generally tied back to the original asset and its market performance.

ERC404 vs ERC1155

While ERC-1155 also supports both token types, it focuses on batch transfers and gas efficiency. ERC-404, in contrast, strives for seamless liquidity transitions and the division of tokens into more accessible units with greater utility.

N.B.: Discover more about ERC-1155 with our practical guide.

Feature ERC-404 ERC-721 ERC-1155
Fungibility Hybrid (transitions between fungible and non-fungible) Non-fungible (unique) Flexible (fungible, non-fungible, or semi-fungible)
Ownership Native fractional Owned by a single address but can implement mechanisms for shared ownership Collective
Availability Marketplaces and DeFi platforms NFT marketplace NFT marketplace
Utility Bridging NFT to DeFi Digital art, collectibles, PFP, in-game items Gaming, ticketing, membership pass

While these points highlight the outstanding features of a new ERC in Ethereum, more distinctions can be explored on a contract level.

Implementation of ERC-404

Now, let’s examine how core features are defined in Pandora’s main contract.

The core logic behind the asset is encoded in the transferFrom function. It is adapted to handle both ERC-20 and 721 tokens and uses amountOrId parameter to decide the transaction path.

  1. When the amountOrId indicates an NFT (i.e., its value is within the range of currently minted NFT IDs), the function treats the transfer as an ERC-721 token transfer;

  2. Otherwise, it handles the operation as an ERC-20 token transfer;

ERC404_transferFrom_function

Image from GitHub

  1. Additionally, it calls the internal _transfer function to update balances to manage minting or burning.

First, it calculates the difference in the number of full units before and after the transfer and burns the corresponding number of NFTs from the sender's address:

 if (!whitelist[from]) {
            uint256 tokens_to_burn = (balanceBeforeSender / unit) -
                (balanceOf[from] / unit);
            for (uint256 i = 0; i < tokens_to_burn; i++) {
                _burn(from);
            }
        }

Then, mints new NFTs to the recipient's address:

 if (!whitelist[to]) {
            uint256 tokens_to_mint = (balanceOf[to] / unit) -
                (balanceBeforeReceiver / unit);
            for (uint256 i = 0; i < tokens_to_mint; i++) {
                _mint(to);
            }

Please note that since Pandora’s launch, the first ERC-404 token project in production, the team tweaked the code to make it more secure and streamlined. The newer version is available on the project’s GitHub repository.

Benefits and Limitations of ERC-404

The reason why the new potential token standard is gaining popularity is in its inherent characteristic — it’s a highly liquid asset attached to an NFT, giving it an increased utility:

  • By lowering the cost for NFT ownership, ERC-404 can dramatically increase market participation and capital fluidity;
  • The new standard may prove useful in various applications from real-world asset (RWA) to DeFi and gaming where players can gradually earn NFTs through in-game achievements.

However, even though it’s called ERC, it’s not yet an official Ethereum Requests for Comments standard, so there’s a higher risk of inconsistencies. Additionally, limited support from existing marketplaces and exchanges can hinder usability and acceptance.

Looking on the bright side, projects adopting the new ERC havent’s haven't fully realized its potential yet, giving rise to endless possibilities for aspiring developers eager to contribute.

Context Banner

Wrapping Up

ERC404’s journey begins with a surge of excitement and hype. However, to truly succeed, it requires time for improvement, adjustment, and finding its place in the market.

Despite this journey, ERC-404 benefits from the solid foundation laid by existing DeFi and NFT markets. For developers, it is not only a promising opportunity but also a stimulating challenge.

Discover a world of possibilities with GetBlock. Get API access to over 50 blockchains, including Ethereum, and connect your dApp to any protocol of your choice. Start now with a free package and discover limitless opportunities.

FAQ

  • What makes ERC-404 unique compared to ERC-20 or ERC-721?

    plus
  • How does ERC-404 impact traditional NFT ownership?

    plus
  • What are the advantages and potential drawbacks of ERC-404 tokens?

    plus
  • Can ERC-404 be used for more than just NFTs?

    plus
Deen Newman

Deen Newman

May 3, 2024

6 min read

twittertwittertelegramtelegramLinkedinLinkedin