Updated 2019-09-13

Using Hyperledger Besu Configuration File

To specify command line options in a file, use a TOML configuration file.

The configuration file can be saved and reused across node startups. To specify the configuration file, use the --config-file option.

To override an option specified in the configuration file, specify the same option on the command line or as an environment variable. If an option is specified in multiple places, the order of priority is command line, environment variable, configuration file.

TOML Specification

The configuration file must be a valid TOML file and is composed of key/value pairs. Each key is the same as the corresponding command line option name without the leading dashes (--).

Values must be be specified according to TOML specifications for string, numbers, arrays, and booleans. Specific differences between the command line and the TOML file format are:

  • Comma-separated lists on the command line are string arrays in the TOML file
  • File paths, hexadecimal numbers, URLs, and <host:port> values must be enclosed in quotes.


The command line reference includes configuration file examples for each option.

Example TOML configuration file

# Valid TOML config file
data-path="~/besudata" # Path

# Network
bootnodes=["enode://[email protected]:4567", "enode://[email protected]:4567", "enode://[email protected]:4567"]




# Chain
genesis-file="~/genesis.json" # Path to the custom genesis file

# Mining

Starting Besu with a Configuration File

besu --config-file=/home/me/me_node/config.toml