Validator Node Setup
Set up a W Chain mainnet validator on node v1.0.8: install, configure, restore the snapshot, stake and run.
This guide sets up a Validator Node on W Chain mainnet (chain ID 171717). A validator stakes 10,000,000 WCO and produces blocks with the rest of the network, so plan for a machine that stays online all the time.
Use node v1.0.8
Since block 24,630,300 (12 October 2026) the network runs the v1.0.8 consensus rules. Older versions can no longer follow the chain. Every command on this page uses v1.0.8.
Mainnet only
This guide is for mainnet. Testnet node packages for v1.0.8 are not published yet. If you need a testnet node, contact the W Chain team.
Already running a validator on an older version?
Don't set up a new node. Follow the upgrade guide instead: it replaces the binary and genesis.json, keeps your keys, config, chaindata and stake, and takes about 10 minutes.
What you will do:
- Prepare the machine and install dependencies (Steps 1–3)
- Download and verify node v1.0.8 and
genesis.json(Steps 4–5) - Create your validator keys and server config (Steps 6–7)
- Restore the chaindata snapshot (Step 8)
- Stake and register on-chain (Steps 9–10)
- Run the node as a service and lock down the firewall (Steps 11–13)
Budget about an hour, most of it waiting for the snapshot download.
Keep your validator private key safe
It controls your entire 10,000,000 WCO stake and can move it in a single transaction with no delay. Store it in a password manager. Never paste it into a chat or a ticket, and never put it on a machine you don't control.
Step 1: Prepare the System
Your machine must meet these minimums:
| Resource | Minimum |
|---|---|
| vCPUs | 4 or more |
| Memory | 16 GB |
| Disk | 1 TB, SSD or NVMe |
| OS | Ubuntu 20.04, 22.04 or 24.04 (x86-64 / amd64) |
| Node.js | v22 with npm v10 or newer |
| Network | 5 Mbps up and down |
Node.js is only needed for the staking scripts in Step 9, not to run the node.
You can run a node on your own dedicated server, but a professional cloud provider such as AWS, DigitalOcean, Azure, GCP, Hetzner or Contabo is recommended.
Step 2: Install Dependencies
sudo apt update && sudo apt upgrade -y
sudo apt install -y git npmThese commands use apt. Adjust them if your system uses a different package manager.
Step 3: Prepare Directory
mkdir -p ~/w-chain && cd ~/w-chainThe rest of this guide assumes the user is ubuntu, so the folder is /home/ubuntu/w-chain. If your user is different, use your own path everywhere you see /home/ubuntu/w-chain.
Step 4: Download Node v1.0.8 and genesis.json
Both come from the v1.0.8 release. It is published for Linux amd64, which is what AWS EC2 and most VPS providers use.
cd ~/w-chain
U=https://github.com/w-chain/node/releases/download/v1.0.8
curl -fL -O $U/w-chain-node-v1.0.8-linux-amd64.tar.gz
curl -fL -O $U/genesis.json
curl -fL -O $U/checksums-v1.0.8.txt
sha256sum -c checksums-v1.0.8.txtcurl prints download progress first. The last two lines must be:
w-chain-node-v1.0.8-linux-amd64.tar.gz: OK
genesis.json: OKIf anything says FAILED, delete the files and download them again.
Unpack the node and give it a short name. The rest of this guide calls it w-chain-node:
tar -xzf w-chain-node-v1.0.8-linux-amd64.tar.gz
mv w-chain-node-linux-amd64 w-chain-node
chmod +x w-chain-nodeDo not edit genesis.json, and always take it from the v1.0.8 release. It switches on the v1.0.8 rules and lists the current bootnodes. An older copy either makes the node stop at block 24,630,300 or points at bootnodes that no longer exist.
Step 5: Verify Files
./w-chain-node version
grep -c wchainv1 genesis.jsonYou should see:
[VERSION INFO]
Release version = v1.0.8
Git branch = fix/v1.0.8
Commit hash = a474bc5bd34e2c35bbc432e7ef2e81a62b99673a
Build time = Thu Oct 8 09:18:20 UTC 2026
4The version must read v1.0.8 and the last line must be 4. If not, go back to Step 4.
Step 6: Initialize Keys and Blockchain Data Directories
This creates the data directory and your validator keys:
./w-chain-node secrets init --data-dir main-chain --insecureIt prints your new identity:
[SECRETS OUTPUT]
Public key (address) = 0x9C107AA6471e3...E9c6EdE083b8f5
BLS Public key = 0x800f1157a49bb59f5e5d790...fe349fa19a3c323f518a4bd4aa963
Node ID = 16Uiu2HAmVbykGW...DUpLgTw7NbDVbKf1Me4DSave all three. You need the address and the BLS public key in Step 10.
You also need the private key of this address. It is the single line in this file:
cat ~/w-chain/main-chain/consensus/validator.keyCopy it somewhere safe (a password manager), then clear your terminal with clear.
The node keeps validator.key on disk because it signs blocks with it. Tighten its permissions. Run this as the same user the node service will run as, or the node can't read its own keys:
chmod 400 ~/w-chain/main-chain/consensus/validator.key
chmod 400 ~/w-chain/main-chain/consensus/validator-bls.keyStep 7: Create Server Config
Keep the node's settings in a config file instead of passing flags. From ~/w-chain, generate the template and open it:
cd ~/w-chain
./w-chain-node server export --type json
nano default-config.jsonSet these values. Use absolute paths:
| Setting | Value | Notes |
|---|---|---|
chain_config | /home/ubuntu/w-chain/genesis.json | The genesis file from Step 4 |
data_dir | /home/ubuntu/w-chain/main-chain | The data directory from Step 6 |
grpc_addr | 127.0.0.1:9632 | Admin API, local only. It has no password |
jsonrpc_addr | 127.0.0.1:8545 | Local only. Never 0.0.0.0 |
network → libp2p_addr | 0.0.0.0:1478 | Peer-to-peer, must be reachable from the internet |
tx_pool → price_limit | 800000000000 | Minimum gas price in wei (800 Gwei) |
seal | true | Required for a validator |
The relevant lines look like this:
"chain_config": "/home/ubuntu/w-chain/genesis.json",
"data_dir": "/home/ubuntu/w-chain/main-chain",
"grpc_addr": "127.0.0.1:9632",
"jsonrpc_addr": "127.0.0.1:8545",
"network": {
...
"libp2p_addr": "0.0.0.0:1478",
...
},
"seal": true,
"tx_pool": {
"price_limit": 800000000000,
...
}A validator should never serve RPC to the internet: an open RPC port gives anyone a direct line into a consensus machine. If you need a public RPC endpoint, run a separate Non-Validator Node.
Step 8: Utilizing Blockchain Backup File
Syncing from scratch takes days and gets slower as the chain grows. Start from the published snapshot instead. The mainnet/latest links always point to the newest snapshot. The current one is from 7 September 2026; your node syncs the remaining blocks from peers after it starts.
cd ~/w-chain/main-chain
B=https://wchain-sanpshot-677276113339-eu-central-1-an.s3.eu-central-1.amazonaws.com/mainnet/latest
curl -fL -O $B/trie.tar.gz
curl -fL -O $B/blockchain.tar.gz
curl -fL -O $B/SHA256SUMSThis is the slowest step: about 16 GB in total.
Verify before unpacking
A truncated download gives a corrupt database that fails in confusing ways later, so check both archives first:
sha256sum -c SHA256SUMSBoth lines must read OK. If one doesn't, delete that archive, download it again and re-check.
Unpack
tar -xzf trie.tar.gz && rm trie.tar.gz
tar -xzf blockchain.tar.gz && rm blockchain.tar.gzmain-chain now holds four directories: the new blockchain and trie, plus consensus and libp2p from Step 6.
Fix ownership
The files must belong to the user the service runs as:
sudo chown -R ubuntu:ubuntu /home/ubuntu/w-chain/main-chainReplace ubuntu:ubuntu with your user and group if they differ. ls -ld /home/ubuntu/w-chain shows them.
Step 9: Staking Contract
Every validator must stake at least 10,000,000 WCO. Misbehaviour can be slashed, which keeps operators honest.
Clone the staking scripts and install their dependencies:
cd ~/w-chain
git clone https://github.com/w-chain/staking-contract.git
cd staking-contract
npm iCreate the environment file:
cp .env.example .env
chmod 600 .env
nano .envYou will see:
#JUST ADD YOUR PRIVATE KEY HERE
PRIVATE_KEY=your_private_key_here
# KEEP THIS AS IS
CONTRACT_ADDRESS=0xfAc510D5dB8cadfF323D4b979D898dc38F3FB6dF
RPC_URL=https://rpc.w-chain.comReplace your_private_key_here with the private key from Step 6. Change nothing else, then save and exit.
This file now holds a key that controls 10 million WCO. Never commit it to Git, and delete it once staking is done. The node itself does not need it.
Step 10: Load up the Stake
First fund your validator address (the public key from Step 6). You need the stake plus gas, so hold at least 10,000,001 WCO.
Stake
cd ~/w-chain/staking-contract
npm run cli stake 10000000On success the script returns a transaction hash.
Register your BLS public key
Use the BLS public key printed in Step 6. This value is only an example:
npm run cli registerBLSPublicKey 0x800f1157a49bb59f5e5d790...fe349fa19a3c323f518a4bd4aa963Confirm
npm run cli isValidator <your address>It should return true.
Both actions are required. A node that stakes but never registers its BLS key cannot take part in consensus. Once both are done, delete .env:
rm ~/w-chain/staking-contract/.envThe new validator joins the active set at the next epoch boundary, which comes about every hour.
Step 11: Create a System Service
Run the node as a systemd service so it survives reboots and restarts if it crashes:
sudo nano /etc/systemd/system/w-chain-node.servicePaste this in:
[Unit]
Description=W Chain Validator Node
After=network.target
StartLimitIntervalSec=1
[Service]
Type=simple
User=ubuntu
WorkingDirectory=/home/ubuntu/w-chain
ExecStart=/home/ubuntu/w-chain/w-chain-node server --config /home/ubuntu/w-chain/default-config.json
Restart=on-failure
RestartSec=5
LimitNOFILE=65535
[Install]
WantedBy=multi-user.targetSave and exit. Adjust User and the paths if your setup differs.
| Line | Why it matters |
|---|---|
Restart=on-failure | Restarts the node if the process dies. Without it, a crash leaves your validator offline until you notice. |
RestartSec=5 | Waits 5 seconds between restart attempts. |
LimitNOFILE=65535 | A node with many peers opens many files; the default limit can be hit under load. |
Step 12: Enable and Run the Node Service
sudo systemctl daemon-reload
sudo systemctl enable w-chain-node.service
sudo systemctl start w-chain-node.serviceYour node now catches up with the network from the snapshot. Watch it:
journalctl -u w-chain-node -fYou want a steady stream of block committed lines with rising block numbers.
Step 13: Firewall
A validator needs one port open to the internet: 1478/tcp (peer-to-peer). Everything else should be closed.
Check what the node listens on:
sudo ss -ltnp | grep w-chain-node| You should see | Meaning |
|---|---|
0.0.0.0:1478 | P2P: must be public |
127.0.0.1:8545 | JSON-RPC: local only ✔ |
127.0.0.1:9632 | Admin API: local only ✔ |
If 8545 or 9632 show 0.0.0.0 or *, fix jsonrpc_addr / grpc_addr in your config (Step 7) and restart. Never expose 9632.
Allow SSH first, or you will lock yourself out. If your SSH port is not 22, use your port number.
sudo apt-get install -y ufw
sudo ufw allow 22/tcp
sudo ufw allow 1478/tcp
sudo ufw default deny incoming
sudo ufw default allow outgoing
sudo ufw --force enable
sudo ufw status verboseufw status should list only your SSH port and 1478, for both IPv4 and IPv6.
If Docker runs on the same machine, its published ports bypass ufw. Bind containers to 127.0.0.1, or use your provider's firewall instead.
Check from outside
Run this on your own computer, not on the server. The server's own firewall doesn't filter its own connections, so testing from the server proves nothing.
nc -zv -G 5 <your-server-ip> 1478
nc -zv -G 5 <your-server-ip> 8545
nc -zv -G 5 <your-server-ip> 9632Port 1478 must succeed. 8545 and 9632 must be refused or time out.
Important Commands to Maintain and Monitor Your Node
Service
sudo systemctl start w-chain-nodeLogging
journalctl -u w-chain-nodeIs my validator actually working?
A running service tells you little: a node can look healthy while contributing nothing. Count the blocks it committed in the last minute instead:
sudo journalctl -u w-chain-node -S -1min | grep -c 'block committed'Blocks come about every 2 seconds, so a healthy node shows about 20–35. A number near 0 means it is not following the chain, even if the service is running.
Troubleshooting
The node does not start: fork is not available: wchainv1…
genesis.json is from v1.0.8 but the binary is older. Repeat Step 4 and check that ./w-chain-node version says v1.0.8.
The node runs but commits no blocks Check these in order:
- Port 1478 is reachable from the internet (see Check from outside). Give it a minute after a restart.
genesis.jsoncame from the v1.0.8 release:grep -c wchainv1 genesis.jsonmust print4.sealistrueand./w-chain-node versionreports v1.0.8.- You completed both actions in Step 10. Check with
npm run cli isValidator <your address>.
Last updated on