How to Run a Polygon Node (Step-by-Step Guide)
Polygon was created to offer a faster solution to Ethereum's scaling problems. It is a layer 2 scaling solution for Ethereum. It processes transactions faster and at a lower cost while relying on Ethereum's security. Running your own node gives you direct access to the network without relying on third-party RPC providers, improving reliability and giving you full control over your data.
This guide walks you through setting up a Polygon full node using binaries. You will install and configure both Heimdall and Bor, download snapshots to speed up syncing, and end up with a fully operational node connected to the Amoy testnet. The guide also includes the equivalent mainnet commands wherever the steps differ.
Set up your Polygon server in minutes
Run high-performance Polygon workloads on customizable bare metal with 24/7 support and crypto payments.
#Prerequisites
To run a Polygon node, ensure your system meets at least the minimum requirements:
-
Ubuntu 24.04 LTS.
-
A non-root user with sudo privileges.
Mainnet minimum system requirements:
-
RAM: 32 GB
-
CPU: 8-core
-
Storage: 4 TB SSD
-
Bandwidth: 1 Gbit/s
Mainnet recommended system requirements:
-
RAM: 64 GB
-
CPU: 16-core
-
Storage: 6 TB SSD
-
Bandwidth: 1 Gbit/s
Amoy testnet minimum system requirements:
-
RAM: 8 GB
-
CPU: 8-core
-
Storage: 1 TB SSD
-
Bandwidth: 1 Gbit/s
Amoy testnet recommended system requirements:
-
RAM: 16 GB
-
CPU: 16-core
-
Storage: 2 TB SSD
-
Bandwidth: 1 Gbit/s
This demonstration uses a dedicated server provided by Cherry Servers.
Set up your Web3 server in minutes
Optimize cost and performance with custom or pre-built dedicated bare metal servers for blockchain workloads. High uptime, instant 24/7 support, pay in crypto.
#Understanding Polygon Nodes
Before moving to the setup process, it's important to understand what Polygon nodes are and their role in the network. This section provides an overview of the different types of nodes in the Polygon architecture, their functions, and how they contribute to the network's overall security and performance.
#What is a Polygon Node
A Polygon node is a computer that participates in the Polygon network. It processes transactions, validates blocks, and helps maintain the network's security.
The Polygon network is divided into three layers:
-
The Ethereum layer: This consists of a set of smart contracts deployed on the Ethereum mainnet.
-
The Heimdall layer: This is a proof-of-stake (PoS) layer made up of Heimdall nodes that run in parallel with Ethereum.
-
The Bor layer: Bor is responsible for block production.
#Types of Polygon Nodes
There are two main types of Polygon nodes:
-
Full nodes: These store a copy of the blockchain and help validate transactions. They can be pruned (storing only recent data) or archived (storing all historical data).
Criteria for selecting a full node:
-
Goals: If your goal is to support the network by validating transactions without participating in block production.
-
Resources: Pruned nodes are more suited for those with limited storage, while archive nodes are best if you need the complete blockchain history and can handle more storage demands.
-
Risk/Rewards: Full nodes do not directly earn rewards like validator nodes. The risk is minimal as they do not engage in consensus, but still play a critical role in network security.
-
-
Validator nodes: These participate in consensus by proposing, validating, and producing new blocks. Running a validator node requires staking POL tokens and meeting specific requirements.
Criteria for selecting a validator node:
-
Goals: Choose this if your goal is to actively participate in securing the network and earn rewards for your contribution.
-
Resources: Validator nodes require higher computational power, reliable uptime, and a financial stake (POL tokens). This option is best suited for those who can meet the technical and staking requirements.
-
Risks/Rewards: Validator nodes can earn staking rewards, but they come with more responsibility. Downtime or failure to meet requirements could result in penalties, making it a higher-risk, higher-reward option.
-
#How to Run a Polygon Node
This section outlines the steps for setting up a Polygon node. It covers a testnet (Amoy) demonstration and provides instructions and commands for running a node on the mainnet. There are various ways to run a Polygon node, including Docker, binaries, Ansible, GCP, and packages. However, this guide will focus on using binaries.
#Step 1: Connect to the server
Start by accessing the server where your Polygon node will run.
ssh user@server_ipaddress
Replace user with your actual server username and server_ipaddress with the IP address of your server.
#Step 2: Update system software and install build-essentials
Before setting up the node, ensure your server is up to date and has the necessary tools for building software.
Update the system’s package list and upgrade all existing software:
sudo apt-get update && sudo apt-get upgrade -y
OutputGet:1 http://repo.cherryservers.com/ubuntu noble InRelease [8,121 B]
Get:2 http://repo.cherryservers.com/ubuntu noble-updates InRelease [8,145 B]
...
Fetched 44.4 MB in 2s (20.3 MB/s)
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
The following package was automatically installed and is no longer required:
grub-pc-bin
Use 'sudo apt autoremove' to remove it.
The following packages have been kept back:
linux-generic linux-headers-generic linux-image-generic
The following packages will be upgraded:
base-files bsdextrautils bsdutils cloud-init curl eject fdisk fwupd ...
... [85 more packages] ...
uuid-runtime vim vim-common vim-runtime vim-tiny wireless-regdb wpasupplicant xxd
95 upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
Need to get 635 MB of archives.
After this operation, 22.8 MB of additional disk space will be used.
Get:1 http://se.archive.ubuntu.com/ubuntu noble-updates/main ...
...
Install essential tools needed for compiling software:
sudo apt-get install -y build-essential jq
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
jq is already the newest version (1.7.1-3ubuntu0.24.04.2).
jq set to manually installed.
...
0 upgraded, 47 newly installed, 0 to remove and 7 not upgraded.
Need to get 66.9 MB of archives.
After this operation, 228 MB of additional disk space will be used.
...
Fetched 66.9 MB in 7s (10.1 MB/s)
...
Setting up build-essential (12.10ubuntu1) ...
Processing triggers for man-db (2.12.0-4build2) ...
Processing triggers for libc-bin (2.39-0ubuntu8.8) ...
#Step 3: Open the required ports and enable the firewall
To allow your Polygon node to communicate with the network, open the following ports:
sudo ufw allow 26656
sudo ufw allow 30303
sudo ufw allow 22/tcp
-
Port
26656is used by Heimdall for peer-to-peer communication. -
Port
30303is used by Bor for peer-to-peer communication. -
Port
22/tcpis for SSH access to your server.
Then enable the firewall:
sudo ufw enable
When prompted, type y and press Enter. You should see output similar to this:
OutputFirewall is active and enabled on system startup
#Step 4: Install Heimdall
Now install Heimdall using the following command:
sudo curl -L https://raw.githubusercontent.com/0xPolygon/install/heimdall-v2/heimdall-v2.sh | bash -s -- <heimdall_version> <network_type> <node_type>
Replace <heimdall_version>, <network_type>, and <node_type> with the appropriate values for your setup:
-
<heimdall_version>: Specify the version of Heimdall you wish to install. -
<network_type>:mainnetoramoy. -
<node_type>:sentry
This command installs the heimdalld binary.
...
downloading heimdall binary package for from 'https://github.com/0xPolygon/heimdall-v2/releases/download/v0.11.0/heimdall-v0.11.0-amd64.deb' to '/tmp/heimdall-temp-dir-W2f5d3aL9DK'...
...
downloading heimdall profile package for from 'https://github.com/0xPolygon/heimdall-v2/releases/download/v0.11.0/heimdall-amoy-sentry-config_v0.11.0-all.deb' to '/tmp/heimdall-temp-dir-W2f5d3aL9DK'...
...
Uninstalling any existing old binary ...
dpkg: warning: ignoring request to remove heimdall which isn't installed
dpkg: warning: ignoring request to remove heimdalld which isn't installed
Installing /tmp/heimdall-temp-dir-W2f5d3aL9DK/heimdall-v0.11.0-amd64.deb ...
Selecting previously unselected package heimdall.
Unpacking heimdall (0.11.0) ...
Setting up heimdall (0.11.0) ...
Selecting previously unselected package heimdall-profile.
Preparing to unpack .../heimdall-amoy-sentry-config_v0.11.0-all.deb ...
{
"moniker": "test-moniker",
"chain_id": "amoy",
"node_id": "daebaf50befb42eae76feed97c74564f74392e70",
...
Unpacking heimdall-profile (0.11.0) ...
Setting up heimdall-profile (0.11.0) ...
Checking heimdalld version ...
0.11.0
heimdall has been installed successfully!
After the installation completes, verify that heimdalld is installed and available in your PATH:
heimdalld version --long
name: heimdall
server_name: heimdalld
client_name: heimdalld
version: 0.11.0
commit: dfd45d5e8d13773093c0cb983856008b7af5dcb0
go: go version go1.26.5 linux/amd64
#Step 5: Configure Heimdall
Next, download the genesis.json file for your target network and place it in /var/lib/heimdall/config/.
For Amoy, run:
cd /var/lib/heimdall/config
sudo curl -fsSL https://storage.googleapis.com/amoy-heimdallv2-genesis/migrated_dump-genesis.json -o genesis.json
For mainnet, run:
cd /var/lib/heimdall/config
sudo curl -fsSL https://storage.googleapis.com/mainnet-heimdallv2-genesis/migrated_dump-genesis.json -o genesis.json
Verify that the genesis file belongs to the expected network:
sudo jq -r '.chain_id' genesis.json
For Amoy, the command should return:
heimdallv2-80002
The mainnet genesis file should return the chain ID for the Polygon mainnet network.
Next, change the ownership of the Heimdall configuration directory to the Heimdall user:
sudo chown -R heimdall:nogroup /var/lib/heimdall
This ensures the heimdall user has the proper permissions to access and modify the files it needs while running the node.
Check the peer configuration
The Amoy and mainnet profile packages both include current seeds and persistent peer addresses in config.toml. You normally do not need to replace these values manually.
Check the values installed with your profile package:
grep -E '^(seeds|persistent_peers)' /var/lib/heimdall/config/config.toml
You should see a populated list on both lines. Compare them against Polygon's current seed and bootnode reference.
Do not copy a seed or persistent-peer list from an older guide. Polygon can change these nodes, so use the values published in the current documentation if you need to update them.
Only change these settings if they are empty or you are having problems establishing peer connections. If necessary, replace them with the current values from Polygon's documentation:
sudo sed -i 's|^seeds =.*|seeds = "<CURRENT_SEED_LIST>"|g' /var/lib/heimdall/config/config.toml
sudo sed -i 's|^persistent_peers =.*|persistent_peers = "<CURRENT_PERSISTENT_PEER_LIST>"|g' /var/lib/heimdall/config/config.toml
Configure the node identity and advertised address
The shipped config.toml includes a default moniker and an external_address that may not belong to your server. Check both:
grep -E '^(moniker|external_address)' /var/lib/heimdall/config/config.toml
moniker is the name used to identify your node and can be changed to any name you prefer.
external_address tells other nodes where they can reach your Heimdall node. If the profile contains an address that does not belong to your server, clear it:
sudo sed -i 's/^external_address = .*/external_address = ""/' /var/lib/heimdall/config/config.toml
You can also set your own node name:
sudo sed -i 's/^moniker = .*/moniker = "your-node-name"/' /var/lib/heimdall/config/config.toml
If your server has a stable public IP address and port 26656 is reachable from the internet, you can instead advertise that address:
external_address = "YOUR_PUBLIC_IP:26656"
Do not leave an address belonging to another server in external_address, as it prevents your node from advertising a valid inbound peer address.
#Step 6: Install Bor
With Heimdall installed, you can proceed to install Bor using the following command:
sudo curl -L https://raw.githubusercontent.com/0xPolygon/install/main/bor.sh | bash -s -- <bor_version> <network_type> <node_type>
-
<bor_version>: Specify the version of Bor you want to install. -
<network_type>:mainnetoramoy. -
<node_type>:sentry
...
downloading bor binary package for from 'https://github.com/0xPolygon/bor/releases/download/v2.10.0/bor-v2.10.0-amd64.deb' to '/tmp/bor-temp-dir-RO0kg3cZ70Q'...
...
downloading bor profile package for from 'https://github.com/0xPolygon/bor/releases/download/v2.10.0/bor-amoy-sentry-config_v2.10.0-all.deb' to '/tmp/bor-temp-dir-RO0kg3cZ70Q'...
...
Uninstalling any existing old binary ...
dpkg: warning: ignoring request to remove bor which isn't installed
Installing /tmp/bor-temp-dir-RO0kg3cZ70Q/bor-v2.10.0-amd64.deb ...
Selecting previously unselected package bor.
Unpacking bor (2.10.0) ...
Setting up bor (2.10.0) ...
Selecting previously unselected package bor-profile.
Preparing to unpack .../bor-amoy-sentry-config_v2.10.0-all.deb ...
Unpacking bor-profile (2.10.0) ...
Setting up bor-profile (2.10.0) ...
Directory /var/lib/bor exists.
Checking bor version ...
Version: 2.10.0
GitCommit: 82d3b610d48468462a504245b5839de66dc86272
bor has been installed successfully!
After the installation completes, verify that Bor is installed:
bor version
Version: 2.10.0
GitCommit: 82d3b610d48468462a504245b5839de66dc86272
#Step 7: Configure Bor
Start with reviewing Bor's configuration file at /var/lib/bor/config.toml. This confirms where Bor stores its chain data and shows which peer-discovery settings are already configured.
Verify the Bor data directory
Check the chain, datadir, and syncmode settings:
grep -E '^(chain|datadir|syncmode)' /var/lib/bor/config.toml
For an Amoy installation, you should see output similar to:
chain = "amoy"
datadir = "/var/lib/bor/data"
syncmode = "full"
The datadir value is important because you will need it when restoring a Bor snapshot later.
With the default configuration, Bor stores its chain database at /var/lib/bor/data/bor/chaindata.
Use the datadir defined in your configuration rather than assuming a path from a snapshot provider. Restoring the snapshot to the wrong directory will cause Bor to ignore the restored chain data and start syncing from scratch.
Check the peer configuration
The Bor profile package already includes peer discovery settings. Review them before making any changes:
grep -A 8 'discovery' /var/lib/bor/config.toml
You should see populated static-nodes and dns settings. Leave these values unchanged if they are present:
[p2p.discovery]
# v5disc = true
# bootnodesv4 = []
# bootnodesv5 = []
# bootnodes = []
static-nodes = [ "enode://bb34e633b1b9dad359c4dbb896b6283232bb198ad843b50b631889da54b9d2ab85abed03c79d306175b6c6cfd5a4c98312cdf5f4eea4603c7b123c4aa328579c@34.89.255.109:30303", "enode://b65beebaa7c7336f3ff9e87873d8f114010369d3e81383ddf3a8ffe1348767f05ca62d12b2a3b8564ba26b2d74c9b37e70783169b41fcab8b016566d65ea3500@34.185.137.160:30303", "enode://71f5bbf43d878d0ce85935072ed9d21c794b0fd6a30503c1ad8064cfe12401331ea7edfba5288d4f83cd575b2cacf1cbdc91edbbec91470c193f98acf78fb04d@34.89.119.250:30303", "enode://2c363f4157582e2598dbdde6b916f41ec5b86ee116f857ea86845722b7e111d1adacfd9608c7c2dcfb5cba639a07a7e7c2c69885207fe32a155ddb87ea74e891@34.89.40.235:30303" ]
# trusted-nodes = []
dns = [ "enrtree://AKUEZKN7PSKVNR65FZDHECMKOJQSGPARGTPPBI7WS2VUL4EGR6XPC@amoy.polygon-peers.io" ]
If Bor has difficulty connecting to peers after it starts, use Polygon's current seed and bootnode reference to obtain the latest peer information. Do not copy static enodes or bootnodes from an older guide because these addresses can change.
Check the Heimdall configuration
Review the Heimdall section of the Bor configuration:
grep -A 4 'heimdall' /var/lib/bor/config.toml
The profile may contain a commented-out section similar to:
# [heimdall]
# url = "http://localhost:1317"
# "bor.without" = false
# grpc-address = ""
Leave this section commented out unless you have a specific reason to override Bor's default Heimdall connection.
Set the correct file ownership
Finally, make sure the bor user owns the Bor configuration and data directory:
sudo chown -R bor:nogroup /var/lib/bor
If you need to confirm the bor user's group, run:
id bor
Use the group reported by your system if it differs from nogroup.
#Step 8: Start Heimdall service
Start the Heimdall service using the following command:
sudo systemctl start heimdalld
Check that the service is running:
sudo systemctl status heimdalld --no-pager
● heimdalld.service - heimdalld
Loaded: loaded (/usr/lib/systemd/system/heimdalld.service; disabled; preset: enabled)
Active: active (running) since Tue 2026-08-25 08:16:05 UTC; 6s ago
Main PID: 31376 (heimdalld)
Tasks: 37 (limit: 76528)
Memory: 347.8M (peak: 419.0M)
CPU: 7.435s
CGroup: /system.slice/heimdalld.service
└─31376 /usr/bin/heimdalld start --home /var/lib/heimdall --chain=amoy --rest-ser…
Aug 25 08:16:10 demo heimdalld[31376]: 2026-08-25T08:16:10.044Z INF Milestone stored succ…83244
Aug 25 08:16:10 demo heimdalld[31376]: 2026-08-25T08:16:10.044Z INF Milestone stored succ…83264
You can follow the Heimdall logs while the node starts and connects to peers:
sudo journalctl -u heimdalld.service -f
If the logs contain a large amount of peer-discovery output from the pex module, you can filter it out:
sudo journalctl -u heimdalld.service -f | grep -v "module=pex"
Check the sync status
Heimdall exposes its CometBFT status endpoint on port 26657. Check the current block height, block time, and synchronization status:
curl -s localhost:26657/status | jq '.result.sync_info'
{
"latest_block_hash": "8ABA33E139078ED7BC10084B9BAA1751E992FB618CDE03FCE9B3209CF75CC155",
"latest_app_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"latest_block_height": "8788501",
"latest_block_time": "2025-06-24T20:00:00Z",
"earliest_block_hash": "8ABA33E139078ED7BC10084B9BAA1751E992FB618CDE03FCE9B3209CF75CC155",
"earliest_app_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"earliest_block_height": "8788501",
"earliest_block_time": "2025-06-24T20:00:00Z",
"catching_up": false
}
Do not use catching_up alone to determine whether Heimdall is synchronized. A new node starts at the height carried by the genesis file rather than at block zero, and catching_up can report false before the node reaches the current chain tip.
Compare latest_block_height and latest_block_time against the current network tip shown by a Polygon block explorer for the network you are running.
If Heimdall fails to progress beyond the height carried by the genesis file after several minutes and the logs report an error such as wrong Block.Header.AppHash, restore a recent Heimdall snapshot instead of continuing to wait for the node to sync from genesis.
#Step 9: Restore a Heimdall snapshot
Restoring a snapshot brings a new node up to a recent block height without waiting for it to sync from the genesis file.
This guide uses PublicNode's Polygon snapshots. Other providers, such as StakeCraft, Stakepool, and VaultStaking, also publish Polygon snapshots.
Before restoring a snapshot, stop the Heimdall service:
sudo systemctl stop heimdalld
Install lz4, which is required to decompress the snapshot:
sudo apt install -y lz4
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following NEW packages will be installed:
lz4
0 upgraded, 1 newly installed, 0 to remove and 7 not upgraded.
Need to get 93.8 kB of archives.
After this operation, 238 kB of additional disk space will be used.
...
Fetched 93.8 kB in 6s (15.2 kB/s)
Setting up lz4 (1.9.4-1build1.1) ...
Back up the validator state
The priv_validator_state.json file contains Heimdall's validator state. Back it up before replacing the data directory because the snapshot contains its own copy.
sudo cp /var/lib/heimdall/data/priv_validator_state.json "$HOME/priv_validator_state.json"
Do not skip this step. Restore your existing priv_validator_state.json after extracting the snapshot. Do not use the copy contained in the snapshot.
Open PublicNode's Polygon snapshot page, locate the Heimdall snapshot for your network, and copy the current download URL.
Do not copy a snapshot URL from this guide. Snapshot filenames and heights change as providers publish new snapshots.
Download the snapshot into the Heimdall directory:
cd /var/lib/heimdall
sudo wget -c "<CURRENT_SNAPSHOT_URL>"
HTTP request sent, awaiting response... 200 OK
Length: 6887826910 (6.4G) [application/x-lz4-compressed-tar]
...
2026-08-24 09:37:02 (111 MB/s) - ‘polygon-amoy-heimdall-pruned-44003420-44003430.tar.lz4’ saved [6887826910/6887826910]
Replace the existing Heimdall data
Remove the existing data directory and recreate it:
sudo rm -rf /var/lib/heimdall/data
sudo mkdir -p /var/lib/heimdall/data
Before extracting the snapshot, inspect its contents to confirm its directory structure:
lz4 -dc <snapshot-file>.tar.lz4 | tar tvf - | head -20
The first entries should contain Heimdall database directories such as application.db.
The archive stores these directories at its top level rather than inside an additional data/ directory, so extract it directly into /var/lib/heimdall/data:
lz4 -dc <snapshot-file>.tar.lz4 \
| sudo tar xf - -C /var/lib/heimdall/data
Restore the validator state
Copy your original validator state back into the restored data directory:
sudo cp "$HOME/priv_validator_state.json" /var/lib/heimdall/data/priv_validator_state.json
Then make sure the Heimdall service user owns the restored files:
sudo chown -R heimdall:nogroup /var/lib/heimdall
If you need to confirm the Heimdall user's group, run:
id heimdall
uid=111(heimdall) gid=65534(nogroup) groups=65534(nogroup)
Use the group reported by your system if it differs from nogroup.
Finally, remove the downloaded snapshot to reclaim disk space:
sudo rm -f /var/lib/heimdall/<snapshot-file>.tar.lz4
Start Heimdall and verify the restored state
Start the service:
sudo systemctl start heimdalld
Heimdall performs initialization and database processing against the restored data before its RPC endpoint becomes available. This can take several minutes, during which curl may return no response.
Check the synchronization status:
curl -s localhost:26657/status | jq -r ' .result.sync_info | "height: \(.latest_block_height)\ntime: \(.latest_block_time)\ncatching_up: \(.catching_up)" '
An empty response means the node is still initializing. Wait a few minutes and run the command again. You can watch the storage upgrade in the service logs while it works.
Once the endpoint responds, you should see a height close to the snapshot's published height:
height: 44116907
time: 2026-08-24T21:34:47.389336092Z
catching_up: true
A snapshot only provides a starting point. Heimdall must still synchronize the blocks produced after the snapshot was created.
You can monitor the service logs while it catches up:
sudo journalctl -u heimdalld.service -f | grep -v "module=pex"
Aug 25 09:21:53 demo heimdalld[31720]: 2026-08-25T09:21:53.280Z INF executed block app_hash=4ECB807DD1E635E12C9809D5939BDCB179BDAE79FCD21C345D964A373A6B07F4 height=44167330 module=state
Aug 25 09:21:53 demo heimdalld[31720]: 2026-08-25T09:21:53.281Z INF committed state block_app_hash=F70B13412C094B72E8EE9649B7E8BCADB69CA7954F7B8BCEB60EE6E1EAB0ED47 height=44167330 module=state
Aug 25 09:21:53 demo heimdalld[31720]: 2026-08-25T09:21:53.291Z INF finalized block block_app_hash=D1D4CCFAC162D931B31038FCF4D873C1DB63A5D2E5DDE9B74F566CB3DAFCBC8C height=44167331 module=state num_txs_res=1 num_val_updates=0
Aug 25 09:21:53 demo heimdalld[31720]: 2026-08-25T09:21:53.291Z INF executed block app_hash=D1D4CCFAC162D931B31038FCF4D873C1DB63A5D2E5DDE9B74F566CB3DAFCBC8C height=44167331 module=state
Aug 25 09:21:53 demo heimdalld[31720]: 2026-08-25T09:21:53.292Z INF committed state block_app_hash=4ECB807DD1E635E12C9809D5939BDCB179BDAE79FCD21C345D964A373A6B07F4 height=44167331 module=state
Continue monitoring the height and block time until the height is close to the current network tip and the block time is current. Compare the values with the appropriate Polygon block explorer.
#Step 10: Restore a Bor snapshot
Bor can be prepared while Heimdall is catching up, but do not start Bor until Heimdall is synchronized.
Bor stores its chain data under the datadir configured in /var/lib/bor/config.toml. Verify the configured location:
grep -E '^(chain|datadir|syncmode)' /var/lib/bor/config.toml
For an Amoy installation, you should see:
chain = "amoy"
datadir = "/var/lib/bor/data"
syncmode = "full"
With this configuration, Bor stores its chain database at /var/lib/bor/data/bor/chaindata.
The exact path matters when extracting the snapshot. Use the datadir from your configuration rather than assuming a path from a snapshot provider's documentation.
Download the Bor snapshot
This guide uses PublicNode's Polygon snapshots. Locate the Bor snapshot for your network and copy the current download URLs.
PublicNode may provide Bor as separate base and part archives. If so, download both. The base archive contains the older chain data, while the part archive contains the more recent data required to bring the snapshot up to its published height.
Do not copy snapshot filenames or URLs from this guide because the snapshot height and filenames change as new snapshots are published.
Download the archives to /var/lib/bor:
cd /var/lib/bor
sudo wget -c "<CURRENT_BASE_SNAPSHOT_URL>"
sudo wget -c "<CURRENT_PART_SNAPSHOT_URL>"
HTTP request sent, awaiting response... 200 OK
Length: 22928496995 (21G) [application/x-lz4-compressed-tar]
...
2026-08-24 10:06:18 (76.6 MB/s) - ‘polygon-amoy-bor-base-0-23132104.tar.lz4’ saved [22928496995/22928496995]
HTTP request sent, awaiting response... 200 OK
Length: 73868883552 (69G) [application/x-lz4-compressed-tar]
...
2026-08-24 10:19:56 (96.4 MB/s) - ‘polygon-amoy-bor-part-23132105-45696768.tar.lz4’ saved [73868883552/73868883552]
Prepare the Bor data directory
The Bor package installs the configuration but does not populate the chain database until Bor starts. If a previous Bor data directory exists, stop the service before replacing it:
sudo systemctl stop bor
Create the data directory if it does not already exist:
sudo mkdir -p /var/lib/bor/data
Then remove the existing chain data. The following command deletes the existing Bor chain database. Only run it if you intend to replace the existing chain data with the snapshot:
sudo rm -rf /var/lib/bor/data/bor/chaindata
Do not remove /var/lib/bor/config.toml or the rest of the Bor configuration.
Inspect the snapshot archive
Before extracting either archive, inspect its contents:
lz4 -dc <base-snapshot-file>.tar.lz4 | tar tvf - | head -5
The listed paths should begin with a bor/ directory, such as bor/chaindata/.... Because the archive already includes the bor/ level, extract it into Bor's configured datadir, /var/lib/bor/data, rather than directly into /var/lib/bor/data/bor/chaindata. If the paths begin with chaindata/ instead, extract into /var/lib/bor/data/bor.
Extract the base archive first:
lz4 -dc <base-snapshot-file>.tar.lz4 \
| sudo tar xf - -C /var/lib/bor/data
Then extract the part archive:
lz4 -dc <part-snapshot-file>.tar.lz4 \
| sudo tar xf - -C /var/lib/bor/data
The second archive should extend the chain data provided by the base archive.
Verify that the chain database exists:
sudo ls /var/lib/bor/data/bor/chaindata
If this reports no such directory, the archive was extracted to the wrong path. The snapshot archives are still on disk at this point, so you can re-extract without downloading again.
Fix the file ownership
Make sure the Bor service user owns the restored data and configuration:
sudo chown -R bor:nogroup /var/lib/bor
If you are unsure which group the bor user belongs to, check it first:
id bor
uid=112(bor) gid=65534(nogroup) groups=65534(nogroup)
Use the group reported by your system rather than assuming that a dedicated bor group exists.
Remove the downloaded snapshot archives after confirming that the extraction completed successfully:
sudo rm -f /var/lib/bor/<base-snapshot-file>.tar.lz4
sudo rm -f /var/lib/bor/<part-snapshot-file>.tar.lz4
#Step 11: Start and verify Bor
Before starting Bor, confirm that Heimdall is caught up:
curl -s localhost:26657/status | jq -r '
.result.sync_info |
"height: \(.latest_block_height)\ntime: \(.latest_block_time)\ncatching_up: \(.catching_up)"
'
height: 44172048
time: 2026-08-25T10:02:41.680343575Z
catching_up: false
Start Bor
Once Heimdall is synchronized, start Bor:
sudo systemctl start bor
Check the service status:
sudo systemctl status bor --no-pager
● bor.service - bor
Loaded: loaded (/usr/lib/systemd/system/bor.service; disabled; preset: enabled)
Active: active (running) since Tue 2026-08-25 10:03:11 UTC; 6s ago
Main PID: 31932 (bor)
Tasks: 36 (limit: 76528)
Memory: 650.8M (peak: 876.7M)
CPU: 12.704s
CGroup: /system.slice/bor.service
└─31932 /usr/bin/bor server -config /var/lib/bor/config.toml
Aug 25 10:03:16 demo bor[31932]: INFO [08-25|10:03:16.894] Started P2P networking …:30303
Aug 25 10:03:16 demo bor[31932]: INFO [08-25|10:03:16.896] IPC endpoint opened …or.ipc
Aug 25 10:03:16 demo bor[31932]: INFO [08-25|10:03:16.897] HTTP server started …osts=*
Aug 25 10:03:16 demo bor[31932]: INFO [08-25|10:03:16.897] Health service endpoint enabl…health
Aug 25 10:03:16 demo bor[31932]: INFO [08-25|10:03:16.897] Started log indexer
Aug 25 10:03:16 demo bor[31932]: INFO [08-25|10:03:16.897] GRPC Server started …1:3131
Aug 25 10:03:16 demo bor[31932]: INFO [08-25|10:03:16.899] Whitelisting milestone deferr… sync"
Aug 25 10:03:16 demo bor[31932]: INFO [08-25|10:03:16.900] Whitelisting checkpoint defer… sync"
Aug 25 10:03:17 demo bor[31932]: INFO [08-25|10:03:17.547] Indexed transactions ….992ms
Aug 25 10:03:17 demo bor[31932]: INFO [08-25|10:03:17.636] Block synchronisation started
You can follow the Bor logs with:
sudo journalctl -u bor.service -f
Aug 25 10:04:01 demo bor[31932]: INFO [08-25|10:04:01.484] Fetching state sync events queryParams="from_id=47727&to_time=2026-08-24T20:40:42Z&pagination.limit=50"
Aug 25 10:04:01 demo bor[31932]: INFO [08-25|10:04:01.486] StateSyncData gas=0 number=45,785,728 lastStateID=47726 "total records"=0 "fetch time"=2 "process time"=0
Aug 25 10:04:01 demo bor[31932]: INFO [08-25|10:04:01.486] StateSyncData gas=0 number=45,785,728 lastStateID=47726 "total records"=0 "fetch time"=3 "process time"=0
Aug 25 10:04:01 demo bor[31932]: INFO [08-25|10:04:01.510] Fetching state updates from Heimdall fromID=47727 to=2026-08-24T20:40:58Z
Aug 25 10:04:01 demo bor[31932]: INFO [08-25|10:04:01.510] Fetching state sync events queryParams="from_id=47727&to_time=2026-08-24T20:40:58Z&pagination.limit=50"
Verify Bor through JSON-RPC
Bor exposes its HTTP JSON-RPC endpoint on port 8545. Check the current block number:
curl -s -X POST http://127.0.0.1:8545 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}'
The result is returned as a hexadecimal value:
{"jsonrpc":"2.0","id":1,"result":"0x2baded0"}
The block number should be at or near the snapshot's published height and should continue increasing as Bor catches up. Compare it with the current height shown by the Polygon Amoy block explorer or the appropriate explorer for your network.
Check whether Bor is still synchronizing:
curl -s -X POST http://127.0.0.1:8545 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"eth_syncing","params":[],"id":1}'
{"jsonrpc":"2.0","id":1,"result":{"currentBlock":"0x2bb0a90","healedBytecodeBytes":"0x0","healedBytecodes":"0x0","healedTrienodeBytes":"0x0","healedTrienodes":"0x0","healingBytecode":"0x0","healingTrienodes":"0x0","highestBlock":"0x2bb5e9a","startingBlock":"0x2ba6766","stateIndexRemaining":"0x0","syncedAccountBytes":"0x0","syncedAccounts":"0x0","syncedBytecodeBytes":"0x0","syncedBytecodes":"0x0","syncedStorage":"0x0","syncedStorageBytes":"0x0","txIndexFinishedBlocks":"0x23dbb0","txIndexRemainingBlocks":"0x0"}}
While Bor is catching up, the result is an object. Three fields matter: startingBlock, currentBlock, and highestBlock. The gap between currentBlock and highestBlock is how far behind the node still is. The remaining fields track snap sync and transaction indexing, neither of which you need for checking sync progress here.
Once Bor reaches the chain tip, the result becomes false:
{"jsonrpc":"2.0","id":1,"result":false}
Finally, check the number of connected peers:
curl -s -X POST http://127.0.0.1:8545 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"net_peerCount","params":[],"id":1}'
{"jsonrpc":"2.0","id":1,"result":"0x33"}
The result is returned as a hexadecimal value. A non-zero result indicates that Bor currently has peer connections.
Enable both services at boot
Neither service is necessarily enabled for automatic startup after a reboot. Enable both services so your node starts automatically:
sudo systemctl enable heimdalld bor
Created symlink /etc/systemd/system/multi-user.target.wants/heimdalld.service → /usr/lib/systemd/system/heimdalld.service.
Created symlink /etc/systemd/system/multi-user.target.wants/bor.service → /usr/lib/systemd/system/bor.service.
Verify that both services are enabled:
systemctl is-enabled heimdalld bor
You should see:
enabled
enabled
At this point, the Heimdall and Bor services are installed, their chain data has been restored from snapshots, and Bor can continue synchronizing with the Polygon network.
Latency from 30ms to 5ms with Cherry Servers
Read how ELSOUL LABO, leading Solana RPC provider, reduced latency from 30 ms to 5 ms with Cherry Servers' high-performance dedicated bare metal, ensuring optimal performance for their users.
#Conclusion
Your Polygon node is now fully synced and operational. It processes transactions and interacts with the network without relying on third-party RPC providers.
If you want to go further, you can set up your node as a validator. Validator nodes participate in consensus and earn staking rewards, but require staking POL tokens and meeting uptime requirements. The Polygon documentation covers the full validator setup process.
| Read Next |
|---|
| How to run an Solana node |
| How to become a Solana validator |
| How to run an Ethereum node |
| How to run a Bitcoin node |
| what is a blockchains server |
Paying too much for your cloud infrastructure?
Switch to blockchain-optimized dedicated bare metal—save up to 60% on your cloud bill and double the performance compared to hyperscale cloud.
We accept Bitcoin and other popular cryptocurrencies.