Exploring Core Token Standards; ERC-20, ERC-721, ERC-1155
A run-through of the main token standards - ERC-20, ERC-721, ERC-1155
A run-through of the main token standards - ERC-20, ERC-721, ERC-1155
Nattynatman
Share
Introduction
In various industries like food production and manufacturing, the use of standards save time, foster collaboration, and ensure compatibility. In the world of blockchain, token standards do just that. They serve as the foundation for creating digital assets on the Ethereum blockchain.
Token standards streamline the process of creating tokens. Imagine the time saved by developers who don't need to reinvent the wheel each time they create a new token, because they have something to refer to!
Specifically, they provide essential guidelines for developing smart contracts and decentralized applications (dApps), ensuring interoperability within the Ethereum ecosystem. These standards cover critical aspects like token transfers, ownership, and security.
Among them, ERC-20 is well-known for fungible tokens, while ERC-721 and ERC-1155 are used for non-fungible tokens (NFTs). Understanding these standards are essential as they each have different use cases.
By the end of this article, you will be able to:
- Understand what EIP & ERC means, and what they do.
- Differentiate between the key features of ERC-20, ERC-721, ERC-1155 and their purposes.
- Engage in the NFT space feeling more knowledgeable!
ERC & EIP
You might have heard of "ERC-20” before, but what do these letters and numbers mean?
"ERC" stands for "Ethereum Request Comment," and it defines the rules for creating and managing tokens on the Ethereum blockchain.
EIP (Ethereum Improvement Proposal) submissions become ERC standards after approval by the Ethereum community. These standards underpin Ethereum's token ecosystem, encouraging innovation and compatibility within the blockchain world.
Fungible vs Non-Fungible
Now, before we move on to the nitty-gritty, let’s prime your brain to recognize the differences between something that is fungible vs something that is non-fungible:
- Fungible
An item that is fungible means it is replaceable with another identical item, carrying the same fundamental value and properties, enabling them to be exchanged for one another seamlessly.
A classic example is a physical $100 US bill. Whether it is crinkled, scrunched up, or has a dirt mark on it, it still carries the same value as any other $100 US bill.
Other examples of fungible items: commodities (oil, precious metals), company shares, bonds, etc.
- Non-fungible
An item that is non-fungible means it is unique and cannot be replaced.
An example is a red 2021 Toyota Camry. There are so many aspects contained in a car that make them distinguishable. Even if on the surface it appears they are both red, have all the same parts, and are in the same condition - the mileage may differ, there could be an internal engine modification, and most discerning of all - the ownership # is unique.
Other examples of non-fungible items: houses, paintings, flight tickets, etc.
☝️ Likewise, when it comes to NFTs, some may visually appear the same, but the underlying properties and token ID may be different, giving them their non-fungible status.
How many token standards are there?
Today, there are approximately 80+ finalised ERC token standards in existence.
If we went through all of them, this article wouldn’t see the light of day.
Fortunately, for the curious, all the ERC proposals can be found here.
📝 Note: there are also token standards that must be adhered to on different blockchains other than Ethereum, such as the BNB Smart Chain (BSC), Solana, and Tron.
Features of ERC-20, ERC-721, and ERC-1155
ERC-20
- The most popular token standard, proposed in 2015 as an EIP, and officially formalised in September 2017.
- Used for fully fungible and divisible assets, such as DAI, USDC, MATIC, and UNI tokens, to name a few. Basically, anything that’s an Ethereum-based token is an ERC-20.
- The standard is not perfect and has some flaws in its design, most notably, that sending tokens to smart contracts built on this standard will result in irrecoverable funds.
- For example, on Etherscan below, we can see UNI token smart contract successfully received >$420k and >110 tokens when it shouldn’t be allowed to, due to users accidentally sending to this address.
ERC-721
- A token standard that defines a non-divisible and fully non-fungible token contract, created in 2017, and has since grown to become the pillar for majority of NFTs we see today.
- Earliest examples of projects that adhered to this token standard are Cryptokitties and Decentraland Land/Parcel NFTs.
- We see the most common use of the ERC-721 standard for digital art, domain names (like .eth ENS), real estate, etc.
- Whilst popular and ideal for representing unique collectibles across various sectors, it lacked functionalities such as batch transferring/deploying, which would be more suitable for other use-cases such as blockchain gaming, inspiring the development of the improved ERC-1155.
ERC-1155
- The token standard is known for being a hybrid, versatile model because it enables developers to create digital assets that are fungible, non-fungible and semi-fungible.
- A token standard proposed by Enjin in 2018.
- Intended to improve the ERC-721 standard, with the ability to:
- batch mint and transfer, where multiple NFTs can be minted and/or transferred in a single transaction, increasing efficiency and reducing transaction costs.
- support multiple types of assets, whether fungible, non-fungible or semi-fungible, with a single contract.
- Commonly used for blockchain games, as there is no need to make every single in-game item unique (it would be quite impractical really!).
- Recent example: Pirate Nation Game. Comparing the top image to the bottom, we can see that the ERC-721 is utilized for the unique pirate NFTs, whilst the ERC-1155 is utilized for the item NFTs which have multiples, and are frequently transacted in-game.
Diving Deeper
For the more technical folk, here are the official documentations for each of the token standards, diving into the anatomy and properties of each:
Conclusion
- Token standards play a critical role in the development and growth of the Ethereum ecosystem, and provide a set of guidelines and specifications, acting as a common language for the creation and implementation of tokens, smart contracts and dApps.
- There are also token standards that must be adhered to on different blockchains other than Ethereum, such as the BNB Smart Chain (BSC), Solana, and Tron.
- EIP Proposals lead to established ERCs.
- ERC Standards have made it easier for developers to create and deploy new applications on Ethereum, ensuring that they’re compatible with other Ethereum-based projects.
- There are over 80+ established ERC token standards, the main ones being:
- ERC-20 = for fungible tokens
- ERC-721 = for non-fungible tokens
- ERC-1155 = hybrid model, ability to batch transfer/deploy tokens amongst other features
- ERC-6551 = mini-wallet (we’ve written about it
- As a developer/builder, it’s essential to consider the right token standard for your specific project requirements.
Recommended by Pluid