Configuration
Nethermind is highly configurable. There are 3 ways of configuring it, listed by priority:
- Command line options (aka arguments or flags)
- Environment variables
- Configuration file
Given the above priority list, an option defined in a more priority way overrides the same option defined elsewhere if any.
The full list of configuration options can be displayed by running:
nethermind -h
Below is the list of the basic command line options followed by an exhaustive list of configuration options by namespace.
The configuration options are case-sensitive and can be defined only once unless stated otherwise.
Basic command line options
-
-d, --baseDbPath <path>
The path to the Nethermind database directory. Defaults to
db
. -
-c, --config <value>
The path to the configuration file or the name (without extension) of any of the configuration files in the configuration directory. Defaults to
mainnet
.Available configurations
Nethermind provides the following pre-built configurations named as the networks they are for. Their respective versions for archive nodes are suffixed
_archive
.base-mainnet
base-mainnet_archive
base-sepolia
base-sepolia_archive
chiado
chiado_archive
energyweb
energyweb_archive
gnosis
gnosis_archive
holesky
holesky_archive
mainnet
mainnet_archive
op-mainnet
op-mainnet_archive
op-sepolia
op-sepolia_archive
sepolia
sepolia_archive
volta
volta_archive
-
-cd, --configsDirectory <path>
The path to the configuration files directory. Defaults to
configs
. -
-dd, --datadir <path>
The path to the Nethermind data directory. Defaults to Nethermind's current directory.
warningThe absolute paths set by
Init.BaseDbPath
,Init.LogDirectory
, orKeyStore.KeyStoreDirectory
options in a configuration file are not overridden by--datadir
. -
-?, -h, --help
Displays the full list of available command line options.
-
-l, --log <level>
Log level (severity). Allowed values:
TRACE
DEBUG
INFO
WARN
ERROR
OFF
. Defaults toINFO
. -
-lcs, --loggerConfigSource <path>
The path to the NLog configuration file. Defaults to
NLog.config
. -
-pd, --pluginsDirectory <path>
The path to the Nethermind plugins directory. Defaults to
plugins
. -
-v, --version
Displays the Nethermind version info.
Options by namespaces
Aura
-
Aura.AllowAuRaPrivateChains
- CLI
- Environment variable
- Configuration file
--Aura.AllowAuRaPrivateChains <value>
NETHERMIND_AURACONFIG_ALLOWAURAPRIVATECHAINS=<value>
{
"Aura": {
"AllowAuRaPrivateChains": <value>
}
}Whether to allow private Aura-based chains only. Do not use with existing Aura-based chains. Allowed values:
true
false
. Defaults tofalse
. -
Aura.ForceSealing
- CLI
- Environment variable
- Configuration file
--Aura.ForceSealing <value>
NETHERMIND_AURACONFIG_FORCESEALING=<value>
{
"Aura": {
"ForceSealing": <value>
}
}Whether to seal empty blocks if mining. Allowed values:
true
false
. Defaults totrue
. -
Aura.Minimum2MlnGasPerBlockWhenUsingBlockGasLimitContract
- CLI
- Environment variable
- Configuration file
--Aura.Minimum2MlnGasPerBlockWhenUsingBlockGasLimitContract <value>
NETHERMIND_AURACONFIG_MINIMUM2MLNGASPERBLOCKWHENUSINGBLOCKGASLIMITCONTRACT=<value>
{
"Aura": {
"Minimum2MlnGasPerBlockWhenUsingBlockGasLimitContract": <value>
}
}Whether to use 2M gas if the contract returns less than that when using
BlockGasLimitContractTransitions
. Allowed values:true
false
. Defaults tofalse
. -
Aura.TxPriorityConfigFilePath
- CLI
- Environment variable
- Configuration file
--Aura.TxPriorityConfigFilePath <value>
NETHERMIND_AURACONFIG_TXPRIORITYCONFIGFILEPATH=<value>
{
"Aura": {
"TxPriorityConfigFilePath": <value>
}
}The path to the transaction priority rules file to use when selecting transactions from the transaction pool. Defaults to
null
. -
Aura.TxPriorityContractAddress
- CLI
- Environment variable
- Configuration file
--Aura.TxPriorityContractAddress <value>
NETHERMIND_AURACONFIG_TXPRIORITYCONTRACTADDRESS=<value>
{
"Aura": {
"TxPriorityContractAddress": <value>
}
}The address of the transaction priority contract to use when selecting transactions from the transaction pool. Defaults to
null
.
Blocks
-
Blocks.BlockProductionTimeoutMs
- CLI
- Environment variable
- Configuration file
--Blocks.BlockProductionTimeoutMs <value>
NETHERMIND_BLOCKSCONFIG_BLOCKPRODUCTIONTIMEOUTMS=<value>
{
"Blocks": {
"BlockProductionTimeoutMs": <value>
}
}Block Production timeout, in milliseconds. Defaults to
4000
. -
Blocks.ExtraData
- CLI
- Environment variable
- Configuration file
--Blocks.ExtraData <value>
NETHERMIND_BLOCKSCONFIG_EXTRADATA=<value>
{
"Blocks": {
"ExtraData": <value>
}
}The block header extra data up to 32 bytes in length. Defaults to
Nethermind
. -
Blocks.GenesisTimeoutMs
- CLI
- Environment variable
- Configuration file
--Blocks.GenesisTimeoutMs <value>
NETHERMIND_BLOCKSCONFIG_GENESISTIMEOUTMS=<value>
{
"Blocks": {
"GenesisTimeoutMs": <value>
}
}Genesis block load timeout, in milliseconds. Defaults to
40000
. -
Blocks.MinGasPrice
- CLI
- Environment variable
- Configuration file
--Blocks.MinGasPrice <value>
NETHERMIND_BLOCKSCONFIG_MINGASPRICE=<value>
{
"Blocks": {
"MinGasPrice": <value>
}
}The minimum gas premium (or the gas price before the London hard fork) for transactions accepted by the block producer. Defaults to
1
. -
Blocks.PreWarmStateOnBlockProcessing
- CLI
- Environment variable
- Configuration file
--Blocks.PreWarmStateOnBlockProcessing <value>
NETHERMIND_BLOCKSCONFIG_PREWARMSTATEONBLOCKPROCESSING=<value>
{
"Blocks": {
"PreWarmStateOnBlockProcessing": <value>
}
}Whether to pre-warm the state when processing blocks. This can lead to an up to 2x speed-up in the main loop block processing. Allowed values:
true
false
. Defaults toTrue
. -
Blocks.RandomizedBlocks
- CLI
- Environment variable
- Configuration file
--Blocks.RandomizedBlocks <value>
NETHERMIND_BLOCKSCONFIG_RANDOMIZEDBLOCKS=<value>
{
"Blocks": {
"RandomizedBlocks": <value>
}
}Whether to change the difficulty of the block randomly within the constraints. Used in NethDev only. Allowed values:
true
false
. Defaults tofalse
. -
Blocks.SecondsPerSlot
- CLI
- Environment variable
- Configuration file
--Blocks.SecondsPerSlot <value>
NETHERMIND_BLOCKSCONFIG_SECONDSPERSLOT=<value>
{
"Blocks": {
"SecondsPerSlot": <value>
}
}The block time slot, in seconds. Defaults to
12
. -
Blocks.TargetBlockGasLimit
- CLI
- Environment variable
- Configuration file
--Blocks.TargetBlockGasLimit <value>
NETHERMIND_BLOCKSCONFIG_TARGETBLOCKGASLIMIT=<value>
{
"Blocks": {
"TargetBlockGasLimit": <value>
}
}The block gas limit that the block producer should try to reach in the fastest possible way based on the protocol rules. If not specified, then the block producer should follow others. Defaults to
null
.
Bloom
-
Bloom.Index
- CLI
- Environment variable
- Configuration file
--Bloom.Index <value>
NETHERMIND_BLOOMCONFIG_INDEX=<value>
{
"Bloom": {
"Index": <value>
}
}Whether to use the Bloom index. The Bloom index speeds up the RPC log searches. Allowed values:
true
false
. Defaults totrue
. -
Bloom.IndexLevelBucketSizes
- CLI
- Environment variable
- Configuration file
--Bloom.IndexLevelBucketSizes <value>
NETHERMIND_BLOOMCONFIG_INDEXLEVELBUCKETSIZES=<value>
{
"Bloom": {
"IndexLevelBucketSizes": <value>
}
}An array of multipliers for index levels. Can be tweaked per chain to boost performance. Defaults to
[4, 8, 8]
. -
Bloom.Migration
- CLI
- Environment variable
- Configuration file
--Bloom.Migration <value>
NETHERMIND_BLOOMCONFIG_MIGRATION=<value>
{
"Bloom": {
"Migration": <value>
}
}Whether to migrate the previously downloaded blocks to the Bloom index. Allowed values:
true
false
. Defaults tofalse
. -
Bloom.MigrationStatistics
- CLI
- Environment variable
- Configuration file
--Bloom.MigrationStatistics <value>
NETHERMIND_BLOOMCONFIG_MIGRATIONSTATISTICS=<value>
{
"Bloom": {
"MigrationStatistics": <value>
}
}Whether the migration statistics should be calculated and output. Allowed values:
true
false
. Defaults tofalse
.