Skip to content
This repository was archived by the owner on Apr 6, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion pages/interop/tutorials/_meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
"message-passing": "Interop message passing",
"deploy-superchain-erc20": "Deploying a SuperchainERC20",
"transfer-superchainERC20": "Transferring a SuperchainERC20",
"custom-superchain-erc20": "Custom SuperchainERC20 tokens",
"custom-superchain-erc20": "Custom SuperchainERC20 tokens",
"upgrade-to-superchain-erc20": "Upgrade ERC20 for Superchain support",
Comment thread
qbzzt marked this conversation as resolved.
Outdated
"bridge-crosschain-eth": "Bridging native cross-chain ETH transfers",
"contract-calls": "Making crosschain contract calls (ping pong)",
"event-reads": "Making crosschain event reads (tic-tac-toe)",
Expand Down
2 changes: 1 addition & 1 deletion pages/interop/tutorials/message-passing.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ The implementation consists of three main components:

5. Create `src/GreetingSender.sol`.

```solidity file=<rootDir>/public/tutorials/GreetingSender.sol hash=bc4d79b54b5d6a007264f9972818f56a
```solidity file=<rootDir>/public/tutorials/GreetingSender.sol#L1-L28 hash=9ed77001810caf52bbaa94da8b0dc5c6
```

<details>
Expand Down
58 changes: 58 additions & 0 deletions pages/interop/tutorials/upgrade-to-superchain-erc20.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
---
title: Upgrading ERC20 to SuperchainERC20
lang: en-US
description: Tutorial on how to take an existing ERC20 and upgrade it to SuperchainERC20.
topic: Interoperability
personas: [Developer]
categories: [Tutorial, Interop]
content_type: article
---

import { Callout, Steps, Card, Cards } from 'nextra/components'

<Callout>
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.
</Callout>

# Upgrading ERC20 to SuperchainERC20

## Overview

This guide explains how to upgrade an ERC20 to a [`SuperchainERC20`](https://github.com/ethereum-optimism/optimism/blob/develop/packages/contracts-bedrock/src/L2/SuperchainERC20.sol) that can teleport across the [Superchain interop cluster](/interop/explainer#superchain-interop-cluster) using the [`SuperchainTokenBridge`](https://github.com/ethereum-optimism/optimism/blob/develop/packages/contracts-bedrock/src/L2/SuperchainTokenBridge.sol) contract. For more information on how it works, [see the explainer](/interop/superchain-erc20).

{/*

I put this warning here when we don't have it on most pages because this tutorial
has, IMHO, code that is a lot more likely to be used in production. It doesn't just
show what is possible, it does the exact job needed.

*/}
Comment thread
qbzzt marked this conversation as resolved.

There are several ways to upgrade an existing ERC20 for interop, depending on your circumstances:

{/*

* If you can upgrade the existing contract, but the address is not available on other chains? In that case, use a custom bridge

upgrade-to-superchain-erc20/custom-bridge.

*/}

| When To Use | Action |
| ----------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------- |
| You can install a new ERC20 contract | [**Deploy New SuperchainERC20 contracts** directly](/interop/tutorials/deploy-superchain-erc20) |
| Existing ERC20 contract cannot be upgraded | [**Implement Lockbox Solution** to bridge between tokens](/interop/tutorials/upgrade-to-superchain-erc20/lockbox) |
| You can deploy to other chains using the same proxy address | [**Perform Contract Upgrade** while maintaining address](/interop/tutorials/upgrade-to-superchain-erc20/contract-upgrade) |

<Cards>
<Card title="Contract upgrade" href="/interop/tutorials/upgrade-to-superchain-erc20/contract-upgrade" icon={<img src="/img/icons/shapes.svg" />} />

<Card title="Lockboxes for permissionless interop" href="/interop/tutorials/upgrade-to-superchain-erc20/lockbox" icon={<img src="/img/icons/shapes.svg" />} />
</Cards>

## Next steps

* Deploy a [SuperchainERC20](/interop/tutorials/deploy-superchain-erc20) to the Superchain
* [Learn more about SuperchainERC20](/interop/superchain-erc20)
* Build a [revolutionary app](/app-developers/get-started) that uses multiple blockchains within the Superchain
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
{
"custom-bridge": "Building a custom bridge"
"contract-upgrade": "Contract upgrade",
"lockbox": "Lockboxes for permissionless interop"
}
Loading