ACP-267: Primary Network validator uptime requirement increases from 80% to 90%.Read the proposal
Set up a Node

Run AvalancheGo with Docker

Learn how to run an Avalanche node using the official AvalancheGo Docker image.

For an easier way to set up and run a node, try the Avalanche Console Node Setup Tool.

Prerequisites

  • Docker installed and running

Verify your Docker installation:

docker --version

Quick Start

Pull and run the latest AvalancheGo release:

docker run -d \
  --name avalanchego \
  -p 9650:9650 \
  -p 9651:9651 \
  -v ~/.avalanchego:/root/.avalanchego \
  avaplatform/avalanchego:v1.14.1

This will start an AvalancheGo node and begin syncing with the Avalanche network.

Replace v1.14.1 with the latest release version from the AvalancheGo releases page.

What This Command Does

FlagPurpose
-dRuns the container in the background (detached mode)
--name avalanchegoNames the container for easy reference
-p 9650:9650Exposes the HTTP API port
-p 9651:9651Exposes the P2P staking port
-v ~/.avalanchego:/root/.avalanchegoPersists chain data and node configuration to your host machine

The volume mount (-v) is important. Without it, chain data is lost when the container is removed and the node will need to re-sync from scratch.

Check Node Status

Once the container is running, check that the node is bootstrapping:

curl -X POST --data '{
    "jsonrpc":"2.0",
    "id"     :1,
    "method" :"info.isBootstrapped",
    "params": {
        "chain": "X"
    }
}' -H 'content-type:application/json;' 127.0.0.1:9650/ext/info

The response will show "isBootstrapped": true once the node has finished syncing.

View Logs

docker logs -f avalanchego

Stop and Restart

docker stop avalanchego
docker start avalanchego

Upgrade to a New Version

To upgrade AvalancheGo, stop the current container, remove it, and run the new version:

docker stop avalanchego
docker rm avalanchego
docker run -d \
  --name avalanchego \
  -p 9650:9650 \
  -p 9651:9651 \
  -v ~/.avalanchego:/root/.avalanchego \
  avaplatform/avalanchego:<NEW_VERSION>

Your chain data is preserved in ~/.avalanchego on the host, so the node will resume from where it left off.

Pass Configuration Flags

You can pass any AvalancheGo configuration flags directly after the image name:

docker run -d \
  --name avalanchego \
  -p 9650:9650 \
  -p 9651:9651 \
  -v ~/.avalanchego:/root/.avalanchego \
  avaplatform/avalanchego:v1.14.1 \
  --http-host=0.0.0.0 \
  --public-ip-resolution-service=opendns

Connect to Fuji Testnet

To run a node on the Fuji testnet instead of Mainnet:

docker run -d \
  --name avalanchego-fuji \
  -p 9650:9650 \
  -p 9651:9651 \
  -v ~/.avalanchego-fuji:/root/.avalanchego \
  avaplatform/avalanchego:v1.14.1 \
  --network-id=fuji

Port Reference

PortProtocolPurpose
9650TCPHTTP API (RPC calls)
9651TCPP2P networking and staking

Ensure these ports are open in your firewall. Port 9651 must be reachable from the internet for your node to participate in the network.

Is this guide helpful?