OP Stack
SuperchainERC20
💡

The SuperchainERC20 standard is ready for production deployments. Please note that the OP Stack interoperability upgrade, required for crosschain messaging, is currently still in active development.

💡

SuperchainERC20s can be deployed on any chain, but will only be interoperable within the Superchain interop cluster.

SuperchainERC20

💡

This tutorial provides a behind the scenes explanation of how SuperchainERC20 tokens are transferred.

The SuperchainERC20 (opens in a new tab) contract implements ERC-7802 (opens in a new tab) to enable asset interoperability within the Superchain.

Asset interoperability allows tokens to move securely across the Superchain by burning tokens on the source chain and minting an equivalent amount on the destination chain. This approach addresses issues such as liquidity fragmentation and poor user experiences caused by asset wrapping or reliance on liquidity pools.

Instead of wrapping assets, this mechanism effectively "teleports" tokens between chains in the Superchain. It provides users with a secure and capital-efficient method for transacting across chains.

Additional features:

  • Simplified deployments: Zero infrastructure cost to make your token cross-chain. Provides a consistent, unified implementation for tokens across all Superchain-compatible networks and a common cross-chain interface for the EVM ecosystem at large.
  • Common standard: Implements ERC-7802 (opens in a new tab), a unified interface that can be used across all of Ethereum to enable cross-chain mint/burn functionality.

How it works

SuperchainERC20 (opens in a new tab) and SuperchainTokenBridge (opens in a new tab) work together to allow ERC-20 tokens to be transferred from one chain to the other.

The initiating message burns tokens on the source chain. The executing message then mints them on the destination chain.

Initiating message (source chain)

  1. The user (or a contract) calls SuperchainTokenBridge.sendERC20 (opens in a new tab).

  2. The token bridge calls SuperchainERC20.crosschainBurn (opens in a new tab) to burn those tokens on the source chain.

  3. The source token bridge calls SuperchainTokenBridge.relayERC20 (opens in a new tab) on the destination token bridge. This call is relayed using L2ToL2CrossDomainMessenger. The call is initiated here, by emitting an initiating message. It will be executed later, after the destination chain receives an executing message to L2ToL2CrossDomainMessenger.

Executing message (destination chain)

  1. The autorelayer (or the user, or any offchain entity) sends an executing message to L2ToL2CrossDomainMessenger to relay the message.

  2. The destination token bridge calls SuperchainERC20.crosschainMint (opens in a new tab) to mint tokens for the user/contract that called SuperchainTokenBridge.sendERC20 originally.

Requirements

Application developers must complete two steps to make their tokens compatible with SuperchainERC20. Setting this up in advance ensures tokens will benefit from interop when it becomes available.

  • Grant permission to SuperchainTokenBridge (address 0x4200000000000000000000000000000000000028) to call crosschainMint and crosschainBurn. If you are using SuperchainERC20 (opens in a new tab) this is already done for you.

  • Deploy the SuperchainERC20 at the same address on every chain in the Superchain where you want your token to be available. If you do not deploy the contract to a specific destination chain, users will be unable to successfully move their tokens to that chain.

⚠️

To ensure security, you must either design the deployer to allow only a specific trusted ERC-20 contract, such as SuperchainERC20, to be deployed through it, or call CREATE2 to deploy the contract directly from an EOA you control.

This precaution is critical because if an unauthorized ERC-20 contract is deployed at the same address on any Superchain network, it could allow malicious actors to mint unlimited tokens and bridge them to the network where the original ERC-20 contract resides.

Next steps