Skip to main content

Networks & metadata

ChainGate provides programmatic access to all supported networks and their metadata through the cg.networks collection. This is useful for dynamically building interfaces, validating inputs, or retrieving consistent information across multiple chains.

You can:

  • Iterate over all supported networks
  • Access detailed network metadata (name, symbol, decimals, address types, etc.)
  • Detect network type (EVM vs UTXO) via instanceof
  • Create custom EVM networks via cg.networks.evmRpc()

Quick example

import { ChainGate } from 'chaingate'

const cg = new ChainGate({ apiKey: 'your-api-key' })

// Iterate all networks
for (const network of cg.networks) {
console.log(`${network.name} (${network.symbol}) — decimals: ${network.decimals}`)
}

// Direct access by name
const btc = cg.networks.bitcoin
console.log(btc.name) // 'Bitcoin'
console.log(btc.symbol) // 'BTC'
console.log(btc.decimals) // 8
console.log(btc.isTestnet) // false

Supported networks

ChainGate currently supports these networks (expanded regularly):

BitcoinBitcoin
EthereumEthereum
DogecoinDogecoin
LitecoinLitecoin
Bitcoin CashBitcoin Cash
Bitcoin TestnetBitcoin Testnet

ChainGate offers three levels of blockchain support, each providing different capabilities:

Native support

Natively supported networks have dedicated API endpoints provided by ChainGate. This means you get access to rich, ready-to-use data that goes far beyond what a standard JSON-RPC node can provide: paginated transaction history, token balances (ERC-20/ERC-721/ERC-1155), NFT metadata, detailed network status, fee estimation, and more.

These networks are available as named properties on cg.networks and return a full-featured UtxoExplorer or EvmExplorer when passed to cg.explore().

NetworkTypeSymbolAccess
BitcoinUTXOBTCcg.networks.bitcoin
LitecoinUTXOLTCcg.networks.litecoin
DogecoinUTXODOGEcg.networks.dogecoin
Bitcoin CashUTXOBCHcg.networks.bitcoincash
Bitcoin TestnetUTXOtBTCcg.networks.bitcointestnet
EthereumEVMETHcg.networks.ethereum

RPC support

ChainGate provides JSON-RPC proxy endpoints for 12 networks, authenticated via your API key. These let you interact with any of these chains using cg.networks.evmRpc() — you get wallets, transfers, balances, fee estimation, and broadcasting. The main difference from native support is that transaction history, token balance aggregation, and NFT metadata endpoints are not available.

All natively supported networks are also available via RPC. The additional RPC-only EVM networks are:

NetworkPropertyChain ID
Soniccg.rpcUrls.sonic146
Polygoncg.rpcUrls.polygon137
Arbitrumcg.rpcUrls.arbitrum42161
Avalanchecg.rpcUrls.avalanche43114
BNB Smart Chaincg.rpcUrls.bnb56
Basecg.rpcUrls.base8453
const polygon = cg.networks.evmRpc({
rpcUrl: cg.rpcUrls.polygon,
chainId: 137,
name: 'Polygon',
symbol: 'POL',
})
const connector = cg.connect(polygon, wallet)

Global endpoint support

The Global explorer (cg.exploreGlobal()) provides cross-network market data, real-time network information, and logo URLs for 34 networks. This includes all natively and RPC-supported networks, plus many additional EVM chains. Use it for dashboards, portfolio views, or any UI that needs prices and network metadata without performing on-chain operations.

NetworkSymbolNetworkSymbol
BitcoinBTCOptimismOP
LitecoinLTCLineaLINEA
DogecoinDOGEPulseChainPLS
Bitcoin CashBCHBlastBLAST
Bitcoin TestnettBTCScrollSCR
EthereumETHGnosis ChainGNO
SonicSUnichainUNI
PolygonPOLopBNBBNB
ArbitrumARBKavaKAVA
AvalancheAVAXMoonbeamGLMR
BNB ChainBNBTaikoTAIKO
BaseBASEChilizCHZ
BerachainBERAEvmosEVMOS
MantleMNTMoonriverMOVR
CeloCELOSyscoinSYS
PeaqPEAQHAQQISLM
SoneiumSONBahamutFTN

Custom EVM networks via RPC

You can interact with any EVM network by providing a JSON-RPC endpoint:

const bsc = cg.networks.evmRpc({
rpcUrl: 'https://bsc-dataseed.binance.org',
chainId: 56,
name: 'BNB Smart Chain',
symbol: 'BNB',
})

// Or use ChainGate's built-in RPC proxy
const polygon = cg.networks.evmRpc({
rpcUrl: cg.rpcUrls.polygon,
chainId: 137,
name: 'Polygon',
symbol: 'POL',
})

const connector = cg.connect(polygon, wallet)

Key points

  • Uniform structure: Every network exposes consistent metadata for UI and logic.
  • Type-safe: cg.networks provides strong typing and autocompletion in TypeScript.
  • Named + iterable: Access networks by name (cg.networks.bitcoin) or iterate with for...of.
  • Custom EVM support: Use cg.networks.evmRpc() to connect to any EVM chain via JSON-RPC.
  • Display-ready: Use name, symbol, decimals, and nativeToken to render clean UIs.