What good is an ERC20 token anyway?

Why you probably don’t need to create a new blockchain.

Unless you’ve been living under a rock, the explosion of popularity of the ERC20 token standard in the last 12 months is probably no surprise to you.

This popularity comes with some advantages, especially with regard to the growth of the ecosystem. But, there are a number of sensible questions to ask yourself about these tokens — the most potent of which is “what are they good for?” — but other great questions include “why would a product need a token?”, “what technical advantages does a token offer over raw Ethereum or other base currency?” and “are there alternatives that we should be considering?”

An ERC20 token provides, most notably, a trackable, provable and secure ledger that allows the movement of a particular marker between users. Being a standard, it allows an ecosystem of tools to emerge — like MyEtherWallet, Etherdelta and MetaMask — which can interact with any token that complies with the standard.

The most important argument in favor of ERC20 over other token models, is that it is ready for use today: there are existing, audited contracts from trusted groups like Consensys and Zeppelin that provide the framework for building various kinds of ERC20-compliant tokens. This is essential in a ecosystem where so much is at stake and dependent on the security of the underlying, usually immutable, codebases.

Consensys and Zeppelin are real good guys.

Although other tokens have emerged since Ethereum and its smart contracts hit the scene, the popularity, flexibility and established ecosystem of Ethereum’s smart contracts is overwhelming. Unless your primary innovation is a new blockchain, the benefits of using the pre-existing, quickly maturing ecosystem of Ethereum should far outweigh the risk of re-inventing the wheel. Unknowns are a risk that must be managed, and when possible; avoided.

With Ethereum, the advantages of decentralization come with a number of costs, mostly related to performance and query-side functionality. These problems, like many computer science problems, can often be solved with carefully selected data structures, built using the data structures available in smart contracts or emitted via the Ethereum Virtual Machine’s event logger.

As an example of such a case, there is no computationally feasible method to directly identify all the transactions that have taken place with a single address as a party — you have to rely on third-party APIs like Etherscan or aggregate the data yourself, accepting either a loss of decentralization or a loss of performance.

An alternative to relying on a third-party API is to make use of a token or similar smart contract, where the underlying contract provides access to the appropriate data structures that your application needs. Then, when a transfer takes place, the data can be updated in a map, a list of addresses can be enumerated or other structures can be produced and either stored, or emitted to the log.

Further, there are economic considerations in a number of the game theoretic models used in smart contract software. Attention Network a number of staking systems. Staking systems have technical requirements necessary to enforce the game theoretic properties that prevent manipulation — they often require efficient access to information like time held, distribution of quantities held, details of supply management and appropriate exposure to changes in value.

Popular implementations of the ERC20 standard have added a number of other interesting pieces of technical utility for software developers — concepts like pausing of transfers of the token can be used to implement structures where trading is constrained to a particular environment, particular individuals or allowable under only a certain set of conditions; concepts like allowances provide a trustless and retractable mechanism for collecting fees and paying for services; custom “governance” functionality can be added to require approval from third parties or even a democratic arbiter to prevent transfers, minting or other infrastructure.

A real life cryptokitty.

While the recent boom in ERC20 tokens is somewhat overwhelming, this is just the beginning of smart contracts for tokens— I believe there is considerable opportunity to apply this technology in ways that no one has even thought of yet. Further, new standards like ERC721, the non-fungible token standard, made popular by Cryptokitties have made “trading cards,” tagged intellectual property ownership and other non-fungible/collectible representations possible on the blockchain. It is just a matter of time before we see collectible-fighting games like Pokémon, collectibles like sports cards and marketplace uses like tagged intellectual property, and supply chain management, end up built upon the functionality of governed tokens.