Skip to main content

Common flags and config file

You configure Prysm with command-line flags, optionally loaded from a YAML file. Prysm doesn’t read flags from environment variables. This page covers how to pass flags and the ones most people set; the generated reference list includes every flag and its default.

Operating system
Network

Pass flags on the command line​

Put flags after the binary name, or after the component name when you use the launcher script:

./prysm.sh beacon-chain \
--mainnet \
--datadir=$HOME/ethereum/data/mainnet/beacon \
--execution-endpoint=http://localhost:8551 \
--jwt-secret=$HOME/ethereum/data/jwt.hex \
--checkpoint-sync-url=https://sync-mainnet.beaconcha.in
  • Write values as --name=value. It's unambiguous, and it's the only form that works for booleans.
  • A boolean flag is on when present (--mainnet). Turn it off with --name=false, not --name false.
  • List flags, such as --peer, can be repeated or take comma-separated values.
  • Run a binary with --help to see the flags your installed version supports.

Use a config file​

--config-file loads flags from a YAML file. Keys are flag names without the leading dashes:

/var/lib/ethereum/beacon/beacon.yaml
mainnet: true
datadir: /var/lib/ethereum/beacon
execution-endpoint: http://localhost:8551
jwt-secret: /var/lib/ethereum/jwt.hex
checkpoint-sync-url: https://sync-mainnet.beaconcha.in
suggested-fee-recipient: '0x0000000000000000000000000000000000000000'
p2p-max-peers: 70
beacon-chain --config-file=/var/lib/ethereum/beacon/beacon.yaml --p2p-max-peers=100

A command-line flag overrides the same key in the file, so this node runs with 100 peers. Keep one shared base file and override values per machine.

A few rules for the file:

  • Use real YAML types: true, not "true"; numbers as numbers; durations as strings such as 30s. A wrong type stops the node with Mismatched type for flag.
  • Write list flags as YAML lists, one item per line.
  • Quote hex addresses ('0x…') so YAML keeps them as strings.
  • Unknown keys are ignored without a warning. After editing the file, check the startup logs to confirm a setting took effect.

Default data directories​

PlatformBeacon node --datadirValidator --wallet-dir
Linux~/.eth2~/.eth2validators/prysm-wallet-v2
macOS~/Library/Eth2~/Library/Eth2Validators/prysm-wallet-v2

The generated reference shows the macOS values. For services, set --datadir explicitly.

Flags most people set​

Use the same network flag, --mainnet, on both the beacon node and the validator client. Mainnet is the default.

Beacon node​

FlagWhat it does
--mainnet / --hoodi / --sepoliaPicks the network. Mainnet is the default. See Networks.
--datadirWhere the beacon database lives. Defaults depend on the OS (see Default data directories).
--accept-terms-of-useAccepts the terms without a prompt. Needed for services and Docker.
--execution-endpointEngine API address of your execution client. Default http://localhost:8551.
--jwt-secretPath to the JWT secret shared with the execution client.
--checkpoint-sync-urlSyncs from a trusted node's recent state in minutes. See Sync from a checkpoint.
--enable-backfillAfter a checkpoint sync, downloads the older blocks in the background. Off by default. See Sync from a checkpoint.
--beacon-db-pruningDeletes blocks and states older than about 5 months so the database stops growing. Off by default. See Disk space.
--suggested-fee-recipientFallback address for priority fees, used when the validator client doesn't set one. See Set your fee recipient.
--http-mev-relayMEV-Boost address. See Use MEV-Boost.
--p2p-host-ipYour public IP, advertised to peers. See Ports, peers and router setup.
--p2p-max-peersPeer limit. Default 70.
--postpone-shutdown-for-proposalsOn stop or restart, waits until no connected validator has a block to propose in the next 2 epochs. Send the signal again to stop at once. See Update and roll back.
--verbosityLog level. Default info.

Validator client​

FlagWhat it does
--mainnet / --hoodi / --sepoliaPicks the network. Must match the beacon node.
--datadirWhere the validator database, including slashing protection history, lives.
--accept-terms-of-useAccepts the terms without a prompt. Needed for services and Docker.
--wallet-dirWallet location. Defaults depend on the OS (see Default data directories).
--wallet-password-fileFile with the wallet password, so the validator client starts unattended.
--beacon-rpc-providerBeacon node to use over gRPC. Default 127.0.0.1:4000.
--suggested-fee-recipientAddress that receives priority fees from your proposals, for all validators. See Set your fee recipient.
--enable-builderRegisters your validators with MEV-Boost builders. See Use MEV-Boost.
--graffitiText included in blocks you propose. See Set graffiti.
--verbosityLog level. Default info.

Feature flags​

Feature flags enable behavior that isn’t the default yet, or disable a new default. Most operators need none; use one only when the release notes or the Prysm team recommend it, and test it on Hoodi first. At startup, the node logs Enabled feature flag or Disabled feature flag for each one you set, and flags change between releases, so review them when you update.