> For the complete documentation index, see [llms.txt](https://docs.fortmatic.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.fortmatic.com/web3-integration/binance-smart-chain.md).

# Binance Smart Chain

## Configure Binance Smart Chain

### Smart Chain

Mainnet Block Explorer URL: <https://bscscan.com>

```javascript
import Fortmatic from 'fortmatic';
import Web3 from 'web3';

const BSCOptions = {
  /* Smart Chain mainnet RPC URL */
  rpcUrl: 'https://bsc-dataseed.binance.org/', 
  chainId: 56 // Smart Chain mainnet chain id
}

// Setting network to Smart Chain
const fm = new Fortmatic('YOUR_LIVE_API_KEY', BSCOptions);
window.web3 = new Web3(fm.getProvider());
```

### Smart Chain - Testnet

Testnet Block Explorer URL: <https://testnet.bscscan.com>

```javascript
import Fortmatic from 'fortmatic';
import Web3 from 'web3';

const BSCOptions = {
/* Smart Chain - Testnet RPC URL */
  rpcUrl: 'https://data-seed-prebsc-1-s1.binance.org:8545/', 
  chainId: 97 // Smart Chain - Testnet chain id
}


// Setting network to Smart Chain - Testnet
const fm = new Fortmatic('YOUR_TEST_API_KEY', BSCOptions);
window.web3 = new Web3(fm.getProvider());
```
