Setting up a Binance Smart Chain (BSC) fullnode is a powerful way to interact directly with the blockchain—whether you're a developer, validator, or blockchain enthusiast. By leveraging Docker, the process becomes streamlined, portable, and consistent across different operating systems. This guide walks you through how to run BSC nodes using Docker, from installation to synchronization checks, with clear steps and best practices.
Whether you're deploying on Mainnet or Testnet, this tutorial ensures your node runs efficiently and securely.
Why Run a BSC Fullnode?
Running your own BSC fullnode gives you:
- Direct access to blockchain data without relying on third-party APIs.
- Enhanced privacy and security for transactions and smart contract interactions.
- The ability to support network decentralization.
- A foundation for building dApps, validators, or explorers.
Using Docker simplifies deployment by containerizing all dependencies, ensuring consistency across environments.
Supported Platforms
You can run the BSC Docker image on the following operating systems:
- macOS
- Linux (e.g., Ubuntu)
- Windows (via Docker Desktop)
This cross-platform compatibility makes it easy to set up a node regardless of your development environment.
Step 1: Install Docker
Before running a BSC node, ensure Docker is installed on your system.
For desktop users, visit the official Docker installation guide for macOS or Windows.
For Ubuntu Linux, follow the engine-specific instructions:
👉 Install Docker Engine on Ubuntu
Post-Installation Setup
Enable Docker to start automatically on boot:
systemctl enable docker.service
systemctl enable containerd.serviceAdd your user to the docker group to run commands without sudo:
usermod -aG docker ubuntu🔐 Log out and back in for group changes to take effect.
Step 2: Pull the BSC Node Docker Image
The official BSC Docker image is hosted on GitHub Container Registry. Pull the latest version:
docker pull ghcr.io/bnb-chain/bsc:latestThis image includes geth, the Go implementation of the Ethereum protocol modified for BSC.
✅ Tip: Use specific tags (e.g., v1.1.18) in production for stability.Step 3: Download Configuration Files
You'll need two critical configuration files: genesis.json and config.toml.
For Mainnet:
wget $(curl -s https://api.github.com/repos/bnb-chain/bsc/releases/latest | grep browser_ | grep mainnet | cut -d '"' -f 4)
unzip mainnet.zipFor Testnet:
wget $(curl -s https://api.github.com/repos/bnb-chain/bsc/releases/latest | grep browser_ | grep testnet | cut -d '"' -f 4)
unzip testnet.zipThese commands fetch the latest release assets containing network-specific configurations.
👉 Learn how to verify node integrity and sync performance after setup.
Step 4: Prepare Data and Config Directories
To persist blockchain data and configurations outside the container, use Docker volume mounting.
Directory Structure
| Purpose | Host Path | Container Path |
|---|---|---|
| Blockchain Data | ./data/node | /bsc/node |
| Configuration Files | ./config | /bsc/config |
Create these directories locally:
mkdir -p config data/nodePlace genesis.json and config.toml inside the config folder.
Step 5: Run the Docker Container
Use the docker run command to launch your BSC node with proper port mapping and volume mounts.
Example Command (Testnet):
docker run \
-v $(pwd)/config:/bsc/config \
-v $(pwd)/data/node:/bsc/node \
-p 8575:8575 \
--rm \
--name bsc \
-it ghcr.io/bnb-chain/bsc:latest \
--http.addr 0.0.0.0 \
--http.port 8575 \
--http.vhosts '*' \
--verbosity 5Key Flags Explained:
-p 8575:8575: Maps Testnet RPC port. Use8545for Mainnet.--http.addr 0.0.0.0: Allows external RPC connections.--http.vhosts '*': Permits all domains to access the HTTP-RPC server.--verbosity 5: Increases log detail for debugging.
🚨 Security Note: In production, restrict --http.vhosts and use authentication layers.Step 6: Access the Node Console
Once the container is running, connect to the Geth JavaScript console:
docker exec -it bsc geth attach http://localhost:8575From here, you can execute Ethereum JSON-RPC commands like:
eth.blockNumber
net.listening
admin.peersThis allows real-time monitoring and interaction with your node.
How to Check Node Synchronization Status
A newly launched node must sync with the network before becoming fully operational.
Method 1: Use Geth Console
Attach to the IPC interface:
geth attach ipc:data/node/geth.ipcThen run:
eth.syncingIf syncing, it returns an object showing current and highest block numbers. When complete, it returns false.
Method 2: Monitor Docker Logs
Check live logs directly from the container:
docker logs -f bscLook for entries like "Imported new chain segment" to confirm progress.
👉 Discover tools that help monitor node health and optimize sync speed.
Frequently Asked Questions (FAQ)
Q1: What’s the difference between BSC Mainnet and Testnet?
A: Mainnet is the live production network where real-value transactions occur. Testnet is a sandbox environment for developers to test dApps without spending real BNB.
Q2: How long does it take to sync a BSC fullnode?
A: Initial sync time varies based on hardware and network speed. With fast storage and bandwidth, it typically takes 2–6 hours. Using a snapshot can reduce this to under an hour.
Q3: Can I use this node for staking or validation?
A: Running a fullnode is the first step, but becoming a validator requires additional setup, including securing BNB tokens and registering as a candidate validator.
Q4: Is Docker necessary to run a BSC node?
A: No, but Docker simplifies dependency management and ensures consistency across systems. It's highly recommended for developers and DevOps teams.
Q5: How do I update my BSC node?
A: Pull the latest Docker image (docker pull ghcr.io/bnb-chain/bsc:latest) and restart the container with the same volumes. Always back up critical data before upgrading.
Q6: What ports does BSC use?
A:
- RPC Port:
8545(Mainnet),8575(Testnet) - WebSocket Port:
8546(Mainnet),8576(Testnet) - P2P Port:
30311(Mainnet),30312(Testnet)
Ensure these are open if behind a firewall.
Core Keywords for SEO
- Run BSC node
- BSC Docker setup
- Deploy Binance Smart Chain node
- Fullnode with Docker
- BSC Testnet node
- Geth on BSC
- Blockchain node synchronization
- Self-hosted BSC node
These keywords have been naturally integrated throughout the content to align with common search queries while maintaining readability.
By following this guide, you now have a fully functional BSC fullnode running in Docker, capable of serving RPC requests, supporting dApp development, or acting as a foundation for further blockchain exploration.
For those looking to deepen their engagement with Web3 infrastructure or explore advanced node management tools, continuous learning and monitoring are key.
👉 Access developer resources and blockchain analytics to enhance your node experience.