跳至主内容

如何添加自定义网络 RPC

MetaMask can access many more networks than just Ethereum mainnet: you can add any EVM-compatible network directly within your wallet, create Solana accounts, and browse non-EVM networks through Snaps.

首字母缩略词 RPC 代表远程过程调用,这是一组协议,可让客户端(例如 MetaMask)与区块链交互。 You can add multiple RPC URLs for a single network and edit the default RPC URL from your list of networks in both Extension and Mobile settings.

备注

Adding a custom RPC URL will disable Smart Transaction capabilities. To re-enable this, you'll need to switch back to the default RPC URL from the network dropdown selector.

On both Mobile and Extension, you can easily add several networks with just a click. You can find this using the following steps:

在钱包的主页上,点击左上方的网络选择器。 向下滚动,直到看到“其他网络”部分。 或者,您也可以在搜索栏中搜索要添加的网络。

Tap the "Add" button next to the network to add it to your MetaMask instance.

MetaMask additional networks
modal

Adding a network manually

If you don’t see a desired network in the list, you can follow these instructions to establish the network connection manually:

  1. 点击网络选择器按钮。 这将显示您已添加的网络列表。

  2. Click "Add custom network":

    MetaMask add network
extension

  3. 将出现一个屏幕,您可以在其中输入要添加的网络的详细信息。 Click "Save" to add the network.

    MetaMask additional networks
modal

Adding or editing RPC URLs

You can add multiple RPC URLs for a single network and edit the default RPC URL from your list of networks in both Extension and Mobile settings.

  1. Click the network icon in the top left of your wallet to show the list of enabled networks.
  2. Locate the desired network you want to edit and click the 3 dots to edit.

MetaMask edit existing network
RPC

  1. Select the Default RPC URL dropdown field and click “Add RPC URL”.
  2. Enter the URL, nickname, and save your configurations.

MetaMask add RPC URL

You can now toggle between various RPC URLs directly from the network drop-down selector when you want to switch providers. To delete any RPC URL, follow the same steps above and click on the trash bin icon to delete.

Adding via Chainlist

如需一种向 MetaMask 添加网络的简易方法,请转到 chainid.network,只需点击几下,即可连接 MetaMask 并添加网络。 请参阅我们的指南,了解详情。

此外,请注意,在一台设备上添加某个网络,那么在另一台设备上访问同一账户时,并不会出现该网络。 If you add it on Extension, it will not automatically be added to your MetaMask Mobile app yet, and vice versa.

如果您卸载了浏览器扩展程序或移动版应用程序,之后您需要使用私钥助记词来恢复您的钱包,自定义网络也需要重新添加。

Was this helpful?
Connect MetaMask to provide feedback
What is this?
This is a trial feedback system that uses Verax to record your feedback as onchain attestations on Linea Mainnet. When you vote, submit a transaction in your wallet.