Skip to content

Instantly share code, notes, and snippets.

@brandonaaskov
Last active May 30, 2022 18:35
Show Gist options
  • Save brandonaaskov/d5d2c5625f8e1010e563ce7d867b2e9b to your computer and use it in GitHub Desktop.
Save brandonaaskov/d5d2c5625f8e1010e563ce7d867b2e9b to your computer and use it in GitHub Desktop.
WalletConnect can take an optional collection of RPC endpoints paired with their chain ID. This list includes some IDs not found on chainlist.org.
// Chain IDs for Ethereum (source: https://docs.metamask.io/guide/ethereum-provider.html#chain-ids)
// Hex Dec Network
// 0x1 1 Ethereum Main Network (Mainnet)
// 0x3 3 Ropsten Test Network
// 0x4 4 Rinkeby Test Network
// 0x5 5 Goerli Test Network
// 0x2a 42 Kovan Test Network
// Look up chainid.network to get a (somewhat) comprehensive list of chain IDs (EVM-based)
export default {
1: [ // Ethereum mainnet
"https://mainnet.infura.io/v3/e9f6c744d37a4043b45c11e192a47378",
"http://127.0.0.1:7545" // Ganache (local)
],
3: [ // Ethereum testnet
"https://ropsten.infura.io/v3/e9f6c744d37a4043b45c11e192a47378"
],
4: [ // Ethereum testnet
"https://rinkeby.infura.io/v3/e9f6c744d37a4043b45c11e192a47378"
],
5: [ // Ethereum testnet
"https://goerli.infura.io/v3/e9f6c744d37a4043b45c11e192a47378"
],
10: [ // Optimism mainnet
"https://optimism-mainnet.infura.io/v3/e9f6c744d37a4043b45c11e192a47378",
"https://mainnet.optimism.io"
],
42: [ // Ethereum testnet
"https://kovan.infura.io/v3/e9f6c744d37a4043b45c11e192a47378"
],
69: [ // Optimism testnet
"https://optimism-kovan.infura.io/v3/e9f6c744d37a4043b45c11e192a47378",
"https://kovan.optimism.io"
],
137: [ // Polygon mainnet
"https://polygon-mainnet.infura.io/v3/e9f6c744d37a4043b45c11e192a47378",
"https://polygon-rpc.com"
],
4160: [ // Algorand mainnet and testnet (handle switch in UI)
"https://mainnet.infura.io/v3/e9f6c744d37a4043b45c11e192a47378"
],
42161: [ // Arbitrum mainnet
"https://arbitrum-mainnet.infura.io/v3/e9f6c744d37a4043b45c11e192a47378",
"https://arb1.arbitrum.io/rpc"
],
80001: [
"https://polygon-mumbai.infura.io/v3/e9f6c744d37a4043b45c11e192a47378"
],
421611: [ // Arbitrum testnet
"https://arbitrum-rinkeby.infura.io/v3/e9f6c744d37a4043b45c11e192a47378",
"https://rinkeby.arbitrum.io/rpc"
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment