Build on X Layer

Network information#

Welcome to X Layer developer documentation.

Connecting to X Layer (Mainnet)#

You can add X Layer mainnet by inputting the following network info:

PropertiesNetwork details
Network nameX Layer mainnet
RPC URLhttps://rpc.xlayer.tech, https://xlayerrpc.okx.com
Chain ID196
Token symbolOKB
Block explorer URLhttps://www.okx.com/web3/explorer/xlayer

Connecting to X Layer (Testnet)#

You can add X Layer testnet by inputting the following network info:

PropertiesNetwork details
Network nameX Layer testnet
RPC URLhttps://testrpc.xlayer.tech/terigon, https://xlayertestrpc.okx.com/terigon
Chain ID1952
Token symbolOKB
Block explorer URLhttps://www.okx.com/web3/explorer/xlayer-test

Deploying smart contracts#

Developing on X Layer is seamless and identical to Ethereum Virtual Machine (EVM). Developers can use their existing code and toolings to deploy on X Layer with much better performance and lower fees. Check out how to deploy smart contracts on X Layer:

Deploy using Hardhat
Guide to deploy contract using Hardhat
Deploy using Truffle
Guide to deploy contract using Truffle
Deploy using Foundry
Guide to deploy contract using Foundry